Fix bdrv_get_geometry to return uint64_t, by Andre Przywara.


git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3825 c046a42c-6fe2-441c-8c8c-71466251a162
diff --git a/qemu-img.c b/qemu-img.c
index f1a8aeb..2dffe8e 100644
--- a/qemu-img.c
+++ b/qemu-img.c
@@ -235,7 +235,7 @@
     const char *fmt = "raw";
     const char *filename;
     const char *base_filename = NULL;
-    int64_t size;
+    uint64_t size;
     const char *p;
     BlockDriver *drv;
 
@@ -300,7 +300,7 @@
         printf(", backing_file=%s",
                base_filename);
     }
-    printf(", size=%" PRId64 " kB\n", (int64_t) (size / 1024));
+    printf(", size=%" PRIu64 " kB\n", size / 1024);
     ret = bdrv_create(drv, filename, size / 512, base_filename, flags);
     if (ret < 0) {
         if (ret == -ENOTSUP) {
@@ -410,7 +410,8 @@
     const char *fmt, *out_fmt, *out_filename;
     BlockDriver *drv;
     BlockDriverState **bs, *out_bs;
-    int64_t total_sectors, nb_sectors, sector_num, bs_offset, bs_sectors;
+    int64_t total_sectors, nb_sectors, sector_num, bs_offset;
+    uint64_t bs_sectors;
     uint8_t buf[IO_BUF_SIZE];
     const uint8_t *buf1;
     BlockDriverInfo bdi;
@@ -655,7 +656,8 @@
     BlockDriver *drv;
     BlockDriverState *bs;
     char fmt_name[128], size_buf[128], dsize_buf[128];
-    int64_t total_sectors, allocated_size;
+    uint64_t total_sectors;
+    int64_t allocated_size;
     char backing_filename[1024];
     char backing_filename2[1024];
     BlockDriverInfo bdi;