Fix Crash

This commit is contained in:
Andrew Pamment 2016-08-08 17:21:04 +10:00
parent 73f9578a25
commit 45be424b8a
2 changed files with 3 additions and 2 deletions

View File

@ -746,6 +746,7 @@ int file_menu(struct user_record *user) {
break; break;
case '}': case '}':
{ {
for (i=user->cur_file_dir;i<conf.file_directory_count;i++) { for (i=user->cur_file_dir;i<conf.file_directory_count;i++) {
if (i + 1 == conf.file_directory_count) { if (i + 1 == conf.file_directory_count) {
i = -1; i = -1;

2
main.c
View File

@ -109,7 +109,7 @@ static int file_sub_handler(void* user, const char* section, const char* name,
int i; int i;
if (strcasecmp(section, "main") == 0) { if (strcasecmp(section, "main") == 0) {
if (strcasecmp(name, "visible sec level")) { if (strcasecmp(name, "visible sec level") == 0) {
fd->sec_level = atoi(value); fd->sec_level = atoi(value);
} }
} else { } else {