From: Karel Zak Date: Fri, 12 Dec 2008 14:13:44 +0000 (+0100) Subject: pg: add gettext call for the help string X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=126836e85286463a77753d198563e59643d1c3fb;p=util-linux pg: add gettext call for the help string Signed-off-by: Karel Zak --- diff --git a/text-utils/pg.c b/text-utils/pg.c index ede5a32b..30c67009 100644 --- a/text-utils/pg.c +++ b/text-utils/pg.c @@ -220,7 +220,8 @@ smalloc(size_t s) { char *m = (char *)malloc(s); if (m == NULL) { - write(2, _("Out of memory\n"), 14); + char *p = _("Out of memory\n"); + write(2, p, strlen(p)); quit(++exitstatus); } return m; @@ -1502,12 +1503,15 @@ found_bw: } goto newcmd; case 'h': + { /* * Help! */ + char *help = _(helpscreen); write(1, copyright + 4, strlen(copyright + 4)); - write(1, helpscreen, strlen(helpscreen)); + write(1, help, strlen(help)); goto newcmd; + } case 'n': /* * Next file.