diff options
author | Joel Kronqvist <joel.kronqvist@iki.fi> | 2024-05-28 12:01:33 +0300 |
---|---|---|
committer | Joel Kronqvist <joel.kronqvist@iki.fi> | 2024-05-28 12:01:33 +0300 |
commit | 41de123de0453274fb2e5b2192548ce274ad8deb (patch) | |
tree | c7b5e16d8616b935f40f046e58a2f12ce56e8d7b /config-parser.c | |
parent | 3be3d993576fbce97cfa6068e427334deb5feb96 (diff) | |
download | stdu-41de123de0453274fb2e5b2192548ce274ad8deb.tar.gz stdu-41de123de0453274fb2e5b2192548ce274ad8deb.zip |
Removed non-C99-compliant declaration after label default in config-parser.cwork/1.0.1
Diffstat (limited to 'config-parser.c')
-rw-r--r-- | config-parser.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/config-parser.c b/config-parser.c index e10275f..ef67a8e 100644 --- a/config-parser.c +++ b/config-parser.c @@ -102,6 +102,7 @@ Result parse_config(int argc, char* argv[]) { size_t opt_i = 0; while (++opt_i < arglen) { + size_t msg_size; char opt = *(argument + opt_i); switch (opt) { case 'h': @@ -113,7 +114,7 @@ Result parse_config(int argc, char* argv[]) { case 'p': next_is_precision = true; if (opt_i != arglen - 1) { - size_t msg_size = 75; + msg_size = 75; char* error_msg = malloc(msg_size); snprintf( @@ -129,7 +130,7 @@ Result parse_config(int argc, char* argv[]) { tmp.help = true; break; default: - size_t msg_size = 20; + msg_size = 20; char* error_msg = malloc(msg_size); snprintf( error_msg, |