diff options
author | Sami Kerola | 2012-07-15 10:39:57 +0200 |
---|---|---|
committer | Karel Zak | 2012-07-16 18:18:22 +0200 |
commit | 289dcc90234680063a336925a99d1ef04e97cbda (patch) | |
tree | cb8656c16143daa406ea9d706406ca12d94d89d3 /login-utils/sulogin.c | |
parent | translation: unify stat error messages (diff) | |
download | kernel-qcow2-util-linux-289dcc90234680063a336925a99d1ef04e97cbda.tar.gz kernel-qcow2-util-linux-289dcc90234680063a336925a99d1ef04e97cbda.tar.xz kernel-qcow2-util-linux-289dcc90234680063a336925a99d1ef04e97cbda.zip |
translation: unify file open error messages
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
Diffstat (limited to 'login-utils/sulogin.c')
-rw-r--r-- | login-utils/sulogin.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/login-utils/sulogin.c b/login-utils/sulogin.c index 7750ad957..7ac493be2 100644 --- a/login-utils/sulogin.c +++ b/login-utils/sulogin.c @@ -213,7 +213,7 @@ static struct passwd *getrootpwent(int try_manually) pwd.pw_gid = 0; if ((fp = fopen(_PATH_PASSWD, "r")) == NULL) { - warn(_("%s: open failed"), _PATH_PASSWD); + warn(_("cannot open %s"), _PATH_PASSWD); return &pwd; } @@ -251,7 +251,7 @@ static struct passwd *getrootpwent(int try_manually) */ strcpy(pwd.pw_passwd, ""); if ((fp = fopen(_PATH_SHADOW_PASSWD, "r")) == NULL) { - warn(_("%s: open failed"), _PATH_PASSWD); + warn(_("cannot open %s"), _PATH_PASSWD); return &pwd; } while ((p = fgets(sline, 256, fp)) != NULL) { @@ -521,7 +521,7 @@ int main(int argc, char **argv) if (tty || (tty = getenv("CONSOLE"))) { if ((fd = open(tty, O_RDWR)) < 0) { - warn(_("%s: open failed"), tty); + warn(_("cannot open %s"), tty); fd = dup(0); } @@ -556,7 +556,7 @@ int main(int argc, char **argv) if (fd > 2) close(fd); if ((fd = open(tty, O_RDWR|O_NOCTTY)) < 0) - warn(_("%s: open failed"), tty); + warn(_("cannot open %s"), tty); else { ioctl(0, TIOCSCTTY, (char *)1); tcsetpgrp(fd, ppgrp); |