The return value of strsignal() may be const and should be treated
as const regardless.
This commit is contained in:
@@ -628,7 +628,7 @@ pty_close(struct command_status *cstat)
|
||||
if (cstat->type == CMD_WSTATUS && WIFSIGNALED(cstat->val)) {
|
||||
int signo = WTERMSIG(cstat->val);
|
||||
if (signo && signo != SIGINT && signo != SIGPIPE) {
|
||||
char *reason = strsignal(signo);
|
||||
const char *reason = strsignal(signo);
|
||||
n = io_fds[SFD_USERTTY] != -1 ?
|
||||
io_fds[SFD_USERTTY] : STDOUT_FILENO;
|
||||
write(n, reason, strlen(reason));
|
||||
|
Reference in New Issue
Block a user