]> xenbits.xensource.com Git - people/liuw/libxenctrl-split/qemu-xen.git/commitdiff
block/qapi: do not redundantly print "actual path"
authorJohn Snow <jsnow@redhat.com>
Mon, 14 Dec 2015 19:55:12 +0000 (14:55 -0500)
committerMax Reitz <mreitz@redhat.com>
Fri, 18 Dec 2015 13:36:17 +0000 (14:36 +0100)
If it happens to match the backing path, that was the actual path.

Signed-off-by: John Snow <jsnow@redhat.com>
Reviewed-by: Max Reitz <mreitz@redhat.com>
Message-id: 1450122916-4706-2-git-send-email-jsnow@redhat.com
Signed-off-by: Max Reitz <mreitz@redhat.com>
block/qapi.c

index c0e877e07e646d90258e8f5209a5bc719f0003e7..563dd3185ddacf94a35b266c5f853b4b6f676f7a 100644 (file)
@@ -676,7 +676,9 @@ void bdrv_image_info_dump(fprintf_function func_fprintf, void *f,
 
     if (info->has_backing_filename) {
         func_fprintf(f, "backing file: %s", info->backing_filename);
-        if (info->has_full_backing_filename) {
+        if (info->has_full_backing_filename &&
+            (strcmp(info->backing_filename,
+                    info->full_backing_filename) != 0)) {
             func_fprintf(f, " (actual path: %s)", info->full_backing_filename);
         }
         func_fprintf(f, "\n");