summary refs log tree commit diff stats
diff options
context:
space:
mode:
-rw-r--r--block/blkdebug.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/block/blkdebug.c b/block/blkdebug.c
index d61ece86a9..c9041ec3d2 100644
--- a/block/blkdebug.c
+++ b/block/blkdebug.c
@@ -240,6 +240,11 @@ static int read_config(BDRVBlkdebugState *s, const char *filename)
     int ret;
     struct add_rule_data d;
 
+    /* Allow usage without config file */
+    if (!*filename) {
+        return 0;
+    }
+
     f = fopen(filename, "r");
     if (f == NULL) {
         return -errno;