fix: io_uring sqpoll issue_time empty when kernel not yet read sq
[fio.git] / engines / net.c
index 91f25774690a16ec9e20576ebb95e3e4e2e9f82e..fec53d74175eedb5d4dd3be6e7a68ece50bb629f 100644 (file)
@@ -938,8 +938,9 @@ static int fio_netio_udp_recv_open(struct thread_data *td, struct fio_file *f)
 
        if (ntohl(msg.magic) != FIO_LINK_OPEN_CLOSE_MAGIC ||
            ntohl(msg.cmd) != FIO_LINK_OPEN) {
-               log_err("fio: bad udp open magic %x/%x\n", ntohl(msg.magic),
-                                                               ntohl(msg.cmd));
+               log_err("fio: bad udp open magic %x/%x\n",
+                       (unsigned int) ntohl(msg.magic),
+                       (unsigned int) ntohl(msg.cmd));
                return -1;
        }
 
@@ -1369,9 +1370,7 @@ static int fio_netio_setup(struct thread_data *td)
        }
 
        if (!td->io_ops_data) {
-               nd = malloc(sizeof(*nd));
-
-               memset(nd, 0, sizeof(*nd));
+               nd = calloc(1, sizeof(*nd));
                nd->listenfd = -1;
                nd->pipes[0] = nd->pipes[1] = -1;
                td->io_ops_data = nd;