diff --git a/plugins/sudoers/auth/fwtk.c b/plugins/sudoers/auth/fwtk.c index 02f3a5ea0..a6e45b253 100644 --- a/plugins/sudoers/auth/fwtk.c +++ b/plugins/sudoers/auth/fwtk.c @@ -56,12 +56,12 @@ fwtk_init(struct passwd *pw, char **promptp, sudo_auth *auth) char resp[128]; /* Response from the server */ if ((confp = cfg_read("sudo")) == (Cfg *)-1) { - warningx(_("cannot read fwtk config")); + warningx(_("unable to read fwtk config")); return AUTH_FATAL; } if (auth_open(confp)) { - warningx(_("cannot connect to authentication server")); + warningx(_("unable to connect to authentication server")); return AUTH_FATAL; } diff --git a/plugins/sudoers/auth/sudo_auth.c b/plugins/sudoers/auth/sudo_auth.c index 103e8f3ba..58ba3ec2b 100644 --- a/plugins/sudoers/auth/sudo_auth.c +++ b/plugins/sudoers/auth/sudo_auth.c @@ -132,7 +132,7 @@ verify_user(struct passwd *pw, char *prompt) if (standalone && auth_switch[1].name != NULL) { audit_failure(NewArgv, "invalid authentication methods"); log_error(0, _("Invalid authentication methods compiled into sudo! " - "You cannot mix standalone and non-standalone authentication.")); + "You may mix standalone and non-standalone authentication.")); return -1; } diff --git a/plugins/sudoers/iolog.c b/plugins/sudoers/iolog.c index de23e474b..36f617614 100644 --- a/plugins/sudoers/iolog.c +++ b/plugins/sudoers/iolog.c @@ -166,14 +166,14 @@ io_nextid(char *iolog_dir, char sessid[7]) } fd = open(pathbuf, O_RDWR|O_CREAT, S_IRUSR|S_IWUSR); if (fd == -1) - log_error(USE_ERRNO, _("cannot open %s"), pathbuf); + log_error(USE_ERRNO, _("unable to open %s"), pathbuf); lock_file(fd, SUDO_LOCK); /* Read seq number (base 36). */ nread = read(fd, buf, sizeof(buf)); if (nread != 0) { if (nread == -1) - log_error(USE_ERRNO, _("cannot read %s"), pathbuf); + log_error(USE_ERRNO, _("unable to read %s"), pathbuf); id = strtoul(buf, &ep, 36); if (buf == ep || id >= SESSID_MAX) log_error(0, _("invalid sequence number %s"), pathbuf); diff --git a/plugins/sudoers/ldap.c b/plugins/sudoers/ldap.c index 3e7a65664..29822fcf4 100644 --- a/plugins/sudoers/ldap.c +++ b/plugins/sudoers/ldap.c @@ -447,11 +447,11 @@ sudo_ldap_parse_uri(const struct ldap_config_list_str *uri_list) if (nldaps != 0) { if (nldap != 0) { - warningx(_("cannot mix ldap and ldaps URIs")); + warningx(_("unable to mix ldap and ldaps URIs")); goto done; } if (ldap_conf.ssl_mode == SUDO_LDAP_STARTTLS) { - warningx(_("cannot mix ldaps and starttls")); + warningx(_("unable to mix ldaps and starttls")); goto done; } ldap_conf.ssl_mode = SUDO_LDAP_SSL; diff --git a/plugins/sudoers/logging.c b/plugins/sudoers/logging.c index 71df37b0c..606ead75e 100644 --- a/plugins/sudoers/logging.c +++ b/plugins/sudoers/logging.c @@ -451,14 +451,14 @@ send_mail(const char *fmt, ...) switch (pid = fork()) { case -1: /* Error. */ - error(1, _("cannot fork")); + error(1, _("unable to fork")); break; case 0: /* Child. */ switch (pid = fork()) { case -1: /* Error. */ - mysyslog(LOG_ERR, _("cannot fork: %m")); + mysyslog(LOG_ERR, _("unable to fork: %m")); _exit(1); case 0: /* Grandchild continues below. */ @@ -508,14 +508,14 @@ send_mail(const char *fmt, ...) (void) sigaction(SIGPIPE, &sa, NULL); if (pipe(pfd) == -1) { - mysyslog(LOG_ERR, _("cannot open pipe: %m")); + mysyslog(LOG_ERR, _("unable to open pipe: %m")); _exit(1); } switch (pid = fork()) { case -1: /* Error. */ - mysyslog(LOG_ERR, _("cannot fork: %m")); + mysyslog(LOG_ERR, _("unable to fork: %m")); _exit(1); break; case 0: @@ -527,7 +527,7 @@ send_mail(const char *fmt, ...) /* Child, set stdin to output side of the pipe */ if (pfd[0] != STDIN_FILENO) { if (dup2(pfd[0], STDIN_FILENO) == -1) { - mysyslog(LOG_ERR, _("cannot dup stdin: %m")); + mysyslog(LOG_ERR, _("unable to dup stdin: %m")); _exit(127); } (void) close(pfd[0]); @@ -561,7 +561,7 @@ send_mail(const char *fmt, ...) set_perms(PERM_FULL_USER|PERM_NOEXIT); execv(mpath, argv); #endif /* NO_ROOT_MAILER */ - mysyslog(LOG_ERR, _("cannot execute %s: %m"), mpath); + mysyslog(LOG_ERR, _("unable to execute %s: %m"), mpath); _exit(127); } break; diff --git a/plugins/sudoers/mon_systrace.c b/plugins/sudoers/mon_systrace.c index a463a7146..c8772848b 100644 --- a/plugins/sudoers/mon_systrace.c +++ b/plugins/sudoers/mon_systrace.c @@ -889,7 +889,7 @@ check_execv(fd, pid, seqnr, askp, policyp, errorp) if (rval == -1 || getcwd(user_cwd, sizeof(user_cwd)) == NULL) { if (rval == -1 && errno == EBUSY) return -1; - warningx("cannot get working directory"); + warningx("unable to get working directory"); (void) strlcpy(user_cwd, "unknown", sizeof(user_cwd)); } diff --git a/plugins/sudoers/sudoreplay.c b/plugins/sudoers/sudoreplay.c index e567966c4..6cada297b 100644 --- a/plugins/sudoers/sudoreplay.c +++ b/plugins/sudoers/sudoreplay.c @@ -371,7 +371,7 @@ main(int argc, char *argv[]) if (ch != -1) (void) fcntl(STDIN_FILENO, F_SETFL, ch | O_NONBLOCK); if (!term_raw(STDIN_FILENO, 1)) - error(1, _("cannot set tty to raw mode")); + error(1, _("unable to set tty to raw mode")); } fdsw = (fd_set *)emalloc2(howmany(STDOUT_FILENO + 1, NFDBITS), sizeof(fd_mask)); diff --git a/plugins/sudoers/visudo.c b/plugins/sudoers/visudo.c index 91f977214..6963c8a97 100644 --- a/plugins/sudoers/visudo.c +++ b/plugins/sudoers/visudo.c @@ -362,7 +362,7 @@ edit_sudoers(struct sudoersfile *sp, char *editor, char *args, int lineno) * Sanity checks. */ if (stat(sp->tpath, &sb) < 0) { - warningx(_("cannot stat temporary file (%s), %s unchanged"), + warningx(_("unable to stat temporary file (%s), %s unchanged"), sp->tpath, sp->path); return FALSE; } diff --git a/src/exec.c b/src/exec.c index 474fcc0f2..bf530b83d 100644 --- a/src/exec.c +++ b/src/exec.c @@ -244,14 +244,14 @@ sudo_execve(struct command_details *details, struct command_status *cstat) * Parent sends signal info to child and child sends back wait status. */ if (socketpair(PF_UNIX, SOCK_DGRAM, 0, sv) == -1) - error(1, _("cannot create sockets")); + error(1, _("unable to create sockets")); /* * We use a pipe to atomically handle signal notification within * the select() loop. */ if (pipe_nonblock(signal_pipe) != 0) - error(1, _("cannot create pipe")); + error(1, _("unable to create pipe")); zero_bytes(&sa, sizeof(sa)); sigemptyset(&sa.sa_mask); diff --git a/src/exec_pty.c b/src/exec_pty.c index 801385e44..02227070b 100644 --- a/src/exec_pty.c +++ b/src/exec_pty.c @@ -819,7 +819,7 @@ exec_monitor(struct command_details *details, int backchannel) * the select() loop. */ if (pipe_nonblock(signal_pipe) != 0) - error(1, _("cannot create pipe")); + error(1, _("unable to create pipe")); /* Reset SIGWINCH and SIGALRM. */ zero_bytes(&sa, sizeof(sa)); diff --git a/src/net_ifs.c b/src/net_ifs.c index 8814a54f2..4c1ad765b 100644 --- a/src/net_ifs.c +++ b/src/net_ifs.c @@ -221,7 +221,7 @@ get_net_ifs(char **addrinfo) sock = socket(AF_INET, SOCK_DGRAM, 0); if (sock < 0) - error(1, _("cannot open socket")); + error(1, _("unable to open socket")); /* * Get interface configuration or return. diff --git a/src/selinux.c b/src/selinux.c index 86a87090c..dc519731a 100644 --- a/src/selinux.c +++ b/src/selinux.c @@ -191,7 +191,7 @@ relabel_tty(const char *ttyn, int ptyfd) /* Reopen pty that was relabeled, std{in,out,err} are reset later. */ se_state.ttyfd = open(ttyn, O_RDWR|O_NOCTTY, 0); if (se_state.ttyfd == -1) { - warning(_("cannot open %s"), ttyn); + warning(_("unable to open %s"), ttyn); if (se_state.enforcing) goto bad; }