comparison cli-main.c @ 1495:0c16b4ccbd54

make signal flags volatile, simplify handling
author Matt Johnston <matt@ucc.asn.au>
date Wed, 14 Feb 2018 23:06:01 +0800
parents f787f60f8e45
children 33b872649eb7
comparison
equal deleted inserted replaced
1494:da095983a60b 1495:0c16b4ccbd54
106 106
107 /* Render the formatted exit message */ 107 /* Render the formatted exit message */
108 vsnprintf(exitmsg, sizeof(exitmsg), format, param); 108 vsnprintf(exitmsg, sizeof(exitmsg), format, param);
109 109
110 /* Add the prefix depending on session/auth state */ 110 /* Add the prefix depending on session/auth state */
111 if (!sessinitdone) { 111 if (!ses.init_done) {
112 snprintf(fullmsg, sizeof(fullmsg), "Exited: %s", exitmsg); 112 snprintf(fullmsg, sizeof(fullmsg), "Exited: %s", exitmsg);
113 } else { 113 } else {
114 snprintf(fullmsg, sizeof(fullmsg), 114 snprintf(fullmsg, sizeof(fullmsg),
115 "Connection to %s@%s:%s exited: %s", 115 "Connection to %s@%s:%s exited: %s",
116 cli_opts.username, cli_opts.remotehost, 116 cli_opts.username, cli_opts.remotehost,