[gdb] Add missing i18n support to error strings (part 2)

Add missing i18n support to some error strings.

Result of:
...
$ find gdb* -type f -name "*.[ch]" -o -name "*.cc" \
    | egrep -v /testsuite/ \
    | xargs sed -i \
        '/"[ \t]*%s[ \t]*"/b l;s/\([ \t]\)error (\("[^"]*"\),$/\1error (_(\2),/;:l'
...

Approved-By: Tom Tromey <tom@tromey.com>
This commit is contained in:
Tom de Vries 2026-06-09 22:14:07 +02:00
parent d7e2f7f484
commit 5a6fa4bf84
3 changed files with 4 additions and 4 deletions

View file

@ -599,7 +599,7 @@ static void
proc_error (procinfo *pi, const char *func, int line)
{
int saved_errno = errno;
error ("procfs: %s line %d, %s: %s",
error (_("procfs: %s line %d, %s: %s"),
func, line, pi->pathname, safe_strerror (saved_errno));
}

View file

@ -178,13 +178,13 @@ find_one_thread (ptid_t ptid)
td_err_e err = thread_db->td_ta_map_lwp2thr_p (thread_db->thread_agent, lwpid,
&th);
if (err != TD_OK)
error ("Cannot get thread handle for LWP %d: %s",
error (_("Cannot get thread handle for LWP %d: %s"),
lwpid, thread_db_err_str (err));
td_thrinfo_t ti;
err = thread_db->td_thr_get_info_p (&th, &ti);
if (err != TD_OK)
error ("Cannot get thread info for LWP %d: %s",
error (_("Cannot get thread info for LWP %d: %s"),
lwpid, thread_db_err_str (err));
threads_debug_printf ("Found thread %ld (LWP %d)",

View file

@ -6047,7 +6047,7 @@ upload_fast_traceframes (void)
if (read_inferior_memory (tf
+ offsetof (struct traceframe, data),
block, ipa_tframe.data_size))
error ("Uploading: Couldn't read traceframe data at %s\n",
error (_("Uploading: Couldn't read traceframe data at %s\n"),
paddress (tf + offsetof (struct traceframe, data)));
}