diff --git a/wmitime/wmgeneral/wmgeneral.c b/wmitime/wmgeneral/wmgeneral.c index c064b39..fb8a8f4 100644 --- a/wmitime/wmgeneral/wmgeneral.c +++ b/wmitime/wmgeneral/wmgeneral.c @@ -385,7 +385,11 @@ void openXwindow(int argc, char *argv[], char *pixmap_bytes[], char *pixmask_bit for (i=1; argv[i]; i++) { if (!strcmp(argv[i], "-display")) { display_name = argv[i+1]; - i++; + if (!display_name) + printf("Please provide an argument for " + "-display.\n"); + else + i++; } if (!strcmp(argv[i], "-geometry")) { geometry = argv[i+1];