Skip to contentSkip to conversation

vhost_net.c: Fix build failure introduced by 0bfcd599e3f5c5679cc7d0165a0a1822e2f60de2

PATCH In review [email protected] 1 participant 2 messages May 27, 2010

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 vhost_net.c: Fix build failure introduced by 0bfcd599e3f5c5679cc7d0165a0a1822e2f60de2

From: Jes Sorensen <[email protected]>

Fix build failure introduced by 0bfcd599e3f5c5679cc7d0165a0a1822e2f60de2

The format statement expects unsigned long on x86_64, but receives unsigned long long, so gcc exits with an error.

---
 hw/vhost_net.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
hw/vhost_net.c +1 -1
index 26dae79..eab310c 100644
@@ -100,7 +100,7 @@ struct vhost_net *vhost_net_init(VLANClientState *backend, int devfd)
     }
     if (~net->dev.features & net->dev.backend_features) {
         fprintf(stderr, "vhost lacks feature mask %" PRIu64 " for backend\n",
-                ~net->dev.features & net->dev.backend_features);
+                (uint64_t)~net->dev.features & net->dev.backend_features);
         vhost_dev_cleanup(&net->dev);
         goto fail;
     }
Signature · 1 line
1.6.5.2
#1 lore raw
Quoted 8 lines · On 05/27/10 12:08, [email protected] wrote:

From: Jes Sorensen <[email protected]>

Fix build failure introduced by 0bfcd599e3f5c5679cc7d0165a0a1822e2f60de2

The format statement expects unsigned long on x86_64, but receives unsigned long long, so gcc exits with an error.

ARGH, sorry, this one was only half finished - please ignore. I'll post a working version in a minute.

Jes