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:
13
scp.c
13
scp.c
@ -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.
|
||||
|
Reference in New Issue
Block a user