Re: BUG #6066: Bad string in German translation causes segfault (user-triggerable) - Mailing list pgsql-bugs

From Christoph Berg
Subject Re: BUG #6066: Bad string in German translation causes segfault (user-triggerable)
Date
Msg-id 20110617091114.GC4130@msgid.df7cb.de
Whole thread Raw
In response to Re: BUG #6066: Bad string in German translation causes segfault (user-triggerable)  (Heikki Linnakangas <heikki.linnakangas@enterprisedb.com>)
Responses Re: BUG #6066: [PATCH] Mark more strings as c-format
List pgsql-bugs
Re: Heikki Linnakangas 2011-06-17 <4DFB137E.4040404@enterprisedb.com>
> So, this is a case where the untranslated string doesn't have a %s
> in it, but the translated one does. We should have a way to check
> those automatically. In fact, I'm surprised if someone somewhere
> hasn't already written such a script, as gettext is used very
> widely. Anyone want to research/write a script?

Actually, msgfmt can do that itself with -c. This can be set in
Makefile.global:

$ grep MSGFMT src/Makefile.global
MSGFMT  = msgfmt -c

Unfortunately that doesn't help in this case, as the bad string isn't
tagged as "#, c-format", but still gets used as such. This seems to be
the case for many errhint() strings. Maybe xgettext should be taught
to treat all errhint() et al arguments as c-strings.

Christoph
--
cb@df7cb.de | http://www.df7cb.de/

pgsql-bugs by date:

Previous
From: Heikki Linnakangas
Date:
Subject: Re: BUG #6066: Bad string in German translation causes segfault (user-triggerable)
Next
From: "Marinos Yannikos"
Date:
Subject: Ident authentication fails due to bind error on server (8.4.8)