1
0
mirror of https://git.tartarus.org/simon/putty.git synced 2025-07-02 12:02:47 -05:00

Prevent network errors from summarily closing the window when CoE is off

[originally from svn r613]
This commit is contained in:
Simon Tatham
2000-09-22 11:04:57 +00:00
parent 985207d4a9
commit e5ef37f3f5
7 changed files with 148 additions and 48 deletions

13
scp.c
View File

@ -157,6 +157,19 @@ void fatalbox(char *fmt, ...)
exit(1);
}
void connection_fatal(char *fmt, ...)
{
char str[0x100]; /* Make the size big enough */
va_list ap;
va_start(ap, fmt);
strcpy(str, "Fatal:");
vsprintf(str+strlen(str), fmt, ap);
va_end(ap);
strcat(str, "\n");
tell_str(stderr, str);
exit(1);
}
/*
* Print an error message and exit after closing the SSH link.