From: Juergen Lock Date: Thu, 25 Mar 2010 21:34:00 +0000 (+0100) Subject: Fix some compilation warnings on FreeBSD hosts X-Git-Tag: v0.13.0-rc0~917 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=d1839d7367303e38e603bc0371d65648b4480078;p=thirdparty%2Fqemu.git Fix some compilation warnings on FreeBSD hosts Signed-off-by: Juergen Lock Signed-off-by: Blue Swirl --- diff --git a/qemu-char.c b/qemu-char.c index a3d6e649670..3e4df8d56c5 100644 --- a/qemu-char.c +++ b/qemu-char.c @@ -1369,7 +1369,7 @@ static CharDriverState *qemu_chr_open_pp(QemuOpts *opts) #if defined(__FreeBSD__) || defined(__FreeBSD_kernel__) || defined(__DragonFly__) static int pp_ioctl(CharDriverState *chr, int cmd, void *arg) { - int fd = (int)chr->opaque; + int fd = (int)(long)chr->opaque; uint8_t b; switch(cmd) { @@ -1415,7 +1415,7 @@ static CharDriverState *qemu_chr_open_pp(QemuOpts *opts) return NULL; chr = qemu_mallocz(sizeof(CharDriverState)); - chr->opaque = (void *)fd; + chr->opaque = (void *)(long)fd; chr->chr_write = null_chr_write; chr->chr_ioctl = pp_ioctl; return chr;