[PATCH v18 07/11] argp: do not display option name translations if __libc_enable_secure

Vivien Kraus vivien@planete-kraus.eu
Sun Nov 23 17:07:34 GMT 2025


---
 argp/argp-help.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/argp/argp-help.c b/argp/argp-help.c
index 34ecc19b38..7557c4dbb2 100644
--- a/argp/argp-help.c
+++ b/argp/argp-help.c
@@ -1218,6 +1218,9 @@ canonical_option_translation (const char *name,
   char *full_msgid = NULL;
   const char *all_names = NULL;
   *allocated = NULL;
+  if (__libc_enable_secure)
+    /* Translations are disabled.  */
+    return name;
   if (__asprintf (&full_msgid, "command-line option\004%s", name) == -1)
     {
       /* *allocated is NULL */
-- 
2.34.1



More information about the Libc-alpha mailing list