diff options
author | Tavian Barnes <tavianator@tavianator.com> | 2017-08-04 22:12:10 -0400 |
---|---|---|
committer | Tavian Barnes <tavianator@tavianator.com> | 2017-08-10 22:33:06 -0400 |
commit | c49dd050080562f829a053d3eb30597fb0c23339 (patch) | |
tree | 23d8ccb8d335b5dffa994fb1f1dc335088636415 /parse.c | |
parent | e8892ce0517958f313a3d9a8888850f98713c4a2 (diff) | |
download | bfs-c49dd050080562f829a053d3eb30597fb0c23339.tar.xz |
parse: Don't allow negative optimization levels
Diffstat (limited to 'parse.c')
-rw-r--r-- | parse.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -760,7 +760,7 @@ static struct expr *parse_optlevel(struct parser_state *state, int arg1, int arg if (strcmp(state->argv[0], "-Ofast") == 0) { *optlevel = 4; - } else if (!parse_int(state, state->argv[0] + 2, optlevel, IF_INT)) { + } else if (!parse_int(state, state->argv[0] + 2, optlevel, IF_INT | IF_UNSIGNED)) { return NULL; } |