]> git.proxmox.com Git - qemu.git/commitdiff
configure: Update configure so that open_by_handle_at check returns correct value
authorAneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>
Tue, 25 Oct 2011 06:40:39 +0000 (12:10 +0530)
committerAneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>
Mon, 31 Oct 2011 07:04:15 +0000 (12:34 +0530)
According to David Gibson for some compiler/libc combinations, open_by_handle_at
test in configure isn't quite right: because the file_handle pointer is never
dereferenced, gcc doesn't complain even if it is undefined. Change the test
as suggested by him.

Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>
configure

index 4f87e0a43ba114266d321d4c9702a9f3b79f6625..19e83943cf385f576c7887eaf4bc3f24ea098a4e 100755 (executable)
--- a/configure
+++ b/configure
@@ -2562,7 +2562,7 @@ fi
 open_by_hande_at=no
 cat > $TMPC << EOF
 #include <fcntl.h>
-int main(void) { struct file_handle *fh; open_by_handle_at(0, fh, 0); }
+int main(void) { struct file_handle fh; open_by_handle_at(0, &fh, 0); }
 EOF
 if compile_prog "" "" ; then
     open_by_handle_at=yes