now for downloads...

This commit is contained in:
Andrew Pamment 2016-08-07 16:53:28 +10:00
parent 42ef279092
commit 0b745be47d

12
files.c
View File

@ -368,7 +368,12 @@ void download(struct user_record *user) {
sqlite3 *db;
sqlite3_stmt *res;
int rc;
struct termios oldit;
struct termios oldot;
if (sshBBS) {
ttySetRaw(STDIN_FILENO, &oldit);
ttySetRaw(STDOUT_FILENO, &oldot);
}
for (i=0;i<tagged_count;i++) {
download_zmodem(user, tagged_files[i]);
@ -418,6 +423,11 @@ void download(struct user_record *user) {
sqlite3_close(db);
}
if (sshBBS) {
tcsetattr(STDIN_FILENO, TCSANOW, &oldit);
tcsetattr(STDOUT_FILENO, TCSANOW, &oldot);
}
for (i=0;i<tagged_count;i++) {
free(tagged_files[i]);
}