diff options
author | Pali Rohár <pali.rohar@gmail.com> | 2013-01-05 12:11:03 +0100 |
---|---|---|
committer | Pali Rohár <pali.rohar@gmail.com> | 2013-01-05 12:11:03 +0100 |
commit | e362f3cab9b58af81db4177104eacd806febf2c9 (patch) | |
tree | a3ee7a90f431cd8b384810d4ff46ea65171a7b38 /src/main.c | |
parent | 9ea9bea09681270de9922eddcbc111dcbdac077d (diff) | |
download | 0xFFFF-e362f3cab9b58af81db4177104eacd806febf2c9.tar.bz2 |
Fix crashing when accessing out of global arrays
Diffstat (limited to 'src/main.c')
-rw-r--r-- | src/main.c | 3 |
1 files changed, 1 insertions, 2 deletions
@@ -300,7 +300,7 @@ static const char * image_tmp[] = { static const char * image_tmp_name(enum image_type type) { - if ( type > sizeof(image_tmp)/sizeof(image_tmp[0]) ) + if ( type >= sizeof(image_tmp)/sizeof(image_tmp[0]) ) return NULL; if ( ! image_tmp[type] || ! image_tmp[type][0] ) @@ -1288,7 +1288,6 @@ int main(int argc, char **argv) { } - } } |