aboutsummaryrefslogtreecommitdiff
path: root/src/main.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/main.c')
-rw-r--r--src/main.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/main.c b/src/main.c
index a1b79f3..74cdef9 100644
--- a/src/main.c
+++ b/src/main.c
@@ -193,7 +193,8 @@ int main(int argc, char *argv[])
};
float *kernel = NULL;
- if (!strcmp(filter, "edge")) kernel = edge;
+ if (!filter) usage();
+ else if (!strcmp(filter, "edge")) kernel = edge;
else if (!strcmp(filter, "blur")) kernel = blur;
else if (!strcmp(filter, "sharpen")) kernel = sharpen;
else usage();
Feel free to download, copy and edit any repo