提交 75825e45 编写于 作者: R Ryota Ozaki 提交者: Daniel Veillard

Fix warning on make due to missing cast (int)

* src/qemu/qemu_monitor.c src/qemu/qemu_monitor_text.c: cast size_t to
  int when passing to '%d'
上级 a32c43d6
......@@ -179,7 +179,7 @@ qemuMonitorIOProcess(qemuMonitorPtr mon)
if (mon->msg && mon->msg->txOffset == mon->msg->txLength)
msg = mon->msg;
VIR_DEBUG("Process %d", mon->bufferOffset);
VIR_DEBUG("Process %d", (int)mon->bufferOffset);
len = qemuMonitorTextIOProcess(mon,
mon->buffer, mon->bufferOffset,
msg);
......@@ -196,7 +196,7 @@ qemuMonitorIOProcess(qemuMonitorPtr mon)
VIR_FREE(mon->buffer);
mon->bufferOffset = mon->bufferLength = 0;
}
VIR_DEBUG("Process done %d used %d", mon->bufferOffset, len);
VIR_DEBUG("Process done %d used %d", (int)mon->bufferOffset, len);
if (msg && msg->finished)
virCondBroadcast(&mon->notify);
return len;
......@@ -319,7 +319,7 @@ qemuMonitorIORead(qemuMonitorPtr mon)
mon->buffer[mon->bufferOffset] = '\0';
}
VIR_DEBUG("Now read %d bytes of data", mon->bufferOffset);
VIR_DEBUG("Now read %d bytes of data", (int)mon->bufferOffset);
return ret;
}
......
......@@ -172,7 +172,7 @@ int qemuMonitorTextIOProcess(qemuMonitorPtr mon ATTRIBUTE_UNUSED,
/* Don't print raw data in debug because its full of control chars */
/*VIR_DEBUG("Process data %d byts of data [%s]", len - used, data + used);*/
VIR_DEBUG("Process data %d byts of data", len - used);
VIR_DEBUG("Process data %d byts of data", (int)(len - used));
/* Look for a non-zero reply followed by prompt */
if (msg && !msg->finished) {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册