summary refs log tree commit diff stats
path: root/qemu-edid.c
diff options
context:
space:
mode:
Diffstat (limited to 'qemu-edid.c')
-rw-r--r--qemu-edid.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/qemu-edid.c b/qemu-edid.c
index 20c958d9c7..92e1a660a7 100644
--- a/qemu-edid.c
+++ b/qemu-edid.c
@@ -92,6 +92,10 @@ int main(int argc, char *argv[])
                 fprintf(stderr, "not a number: %s\n", optarg);
                 exit(1);
             }
+            if (dpi == 0) {
+                fprintf(stderr, "cannot be zero: %s\n", optarg);
+                exit(1);
+            }
             break;
         case 'v':
             info.vendor = optarg;