From: Benno Schulenberg Date: Sat, 22 Jun 2019 13:34:35 +0000 (+0200) Subject: pstree: use separate fprintf() calls for compilation alternatives X-Git-Tag: v23.3~12 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=d08798745562eebc5dfee0c3c01c75895328fe7a;p=psmisc pstree: use separate fprintf() calls for compilation alternatives Alternative strings should be self-contained, otherwise xgettext() will glue the strings together into a msgid that will never occur. Also, add the missing option -T to the synopsis of the command. --- diff --git a/src/pstree.c b/src/pstree.c index e4fed4d..6614d8e 100644 --- a/src/pstree.c +++ b/src/pstree.c @@ -1085,16 +1085,21 @@ static void fix_orphans(security_context_t scontext) static void usage(void) { - fprintf(stderr, - _ - ( #ifdef WITH_SELINUX - "Usage: pstree [-acglpsStuZ] [ -h | -H PID ] [ -n | -N type ]\n" + fprintf(stderr, _( + "Usage: pstree [-acglpsStTuZ] [ -h | -H PID ] [ -n | -N type ]\n" + " [ -A | -G | -U ] [ PID | USER ]\n" + " or: pstree -V\n")); #else /*WITH_SELINUX */ - "Usage: pstree [-acglpsStu] [ -h | -H PID ] [ -n | -N type ]\n" -#endif /*WITH_SELINUX */ + fprintf(stderr, _( + "Usage: pstree [-acglpsStTu] [ -h | -H PID ] [ -n | -N type ]\n" " [ -A | -G | -U ] [ PID | USER ]\n" - " pstree -V\n" "Display a tree of processes.\n\n" + " or: pstree -V\n")); +#endif /*WITH_SELINUX */ + fprintf(stderr, _( + "\n" + "Display a tree of processes.\n\n")); + fprintf(stderr, _( " -a, --arguments show command line arguments\n" " -A, --ascii use ASCII line drawing characters\n" " -c, --compact don't compact identical subtrees\n"