summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 786a6d4)
raw | patch | inline | side by side (parent: 786a6d4)
author | Jonathan Neuschäfer <j.neuschaefer@gmx.net> | |
Sat, 3 Sep 2011 22:43:06 +0000 (00:43 +0200) | ||
committer | Jonathan Neuschäfer <j.neuschaefer@gmx.net> | |
Fri, 16 Sep 2011 19:52:03 +0000 (21:52 +0200) |
src/options.c | patch | blob | history |
diff --git a/src/options.c b/src/options.c
index 398a0688f11a0feca4135507be7f23b107dacb05..aade81cfc1f79130de6da8d33066648bfa78f9c9 100644 (file)
--- a/src/options.c
+++ b/src/options.c
#include <string.h>
#include <glib.h>
-#define MAX_LONGOPT_LENGTH 32
-
#define ERROR_UNKNOWN_OPTION 0x01
#define ERROR_BAD_ARGUMENT 0x02
#define ERROR_GOT_ARGUMENT 0x03
printf("Usage: %s [OPTION]...\n", PACKAGE);
for (i = 0; i < option_table_size; ++i) {
- char tmp[MAX_LONGOPT_LENGTH];
+ char tmp[32];
if (option_table[i].argument)
- g_snprintf(tmp, MAX_LONGOPT_LENGTH, "%s=%s",
+ g_snprintf(tmp, sizeof(tmp), "%s=%s",
option_table[i].longopt,
option_table[i].argument);
else