Introduction
Introduction Statistics Contact Development Disclaimer Help
arg.h: fixed argv checks order - dmenu - my customized version of dmenu (hiltjo…
git clone git://git.codemadness.org/dmenu
Log
Files
Refs
README
LICENSE
---
commit b3d9451c2ddfad7c1b10e9a868afed4d92b37e41
parent 3de85ca21cedf2a9f67755afc8ef031a9170b96a
Author: Lucas Gabriel Vuotto <[email protected]>
Date: Mon, 22 Feb 2016 11:03:36 -0300
arg.h: fixed argv checks order
This prevents accessing to a potentially out-of-bounds memory section.
Signed-off-by: Lucas Gabriel Vuotto <[email protected]>
Diffstat:
M arg.h | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/arg.h b/arg.h
@@ -10,8 +10,8 @@ extern char *argv0;
/* use main(int argc, char *argv[]) */
#define ARGBEGIN for (argv0 = *argv, argv++, argc--;\
- argv[0] && argv[0][1]\
- && argv[0][0] == '-';\
+ argv[0] && argv[0][0] == '-'\
+ && argv[0][1];\
argc--, argv++) {\
char argc_;\
char **argv_;\
You are viewing proxied material from codemadness.org. The copyright of proxied material belongs to its original authors. Any comments or complaints in relation to proxied material should be directed to the original authors of the content concerned. Please see the disclaimer for more details.