Fix Crash
This commit is contained in:
parent
73f9578a25
commit
45be424b8a
3
files.c
3
files.c
@ -422,7 +422,7 @@ void download(struct user_record *user) {
|
|||||||
sqlite3_finalize(res);
|
sqlite3_finalize(res);
|
||||||
sqlite3_close(db);
|
sqlite3_close(db);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (sshBBS) {
|
if (sshBBS) {
|
||||||
tcsetattr(STDIN_FILENO, TCSANOW, &oldit);
|
tcsetattr(STDIN_FILENO, TCSANOW, &oldit);
|
||||||
tcsetattr(STDOUT_FILENO, TCSANOW, &oldot);
|
tcsetattr(STDOUT_FILENO, TCSANOW, &oldot);
|
||||||
@ -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
2
main.c
@ -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 {
|
||||||
|
Reference in New Issue
Block a user