Skip to content

Commit 800981f

Browse files
committed
Merge branch 'tr/maint-parseopt-avoid-empty'
A workaround to avoid doing _(""), which translates to unwanted magic string in the .po files. * tr/maint-parseopt-avoid-empty: gettext: do not translate empty string
2 parents bdac578 + 0c3a433 commit 800981f

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

gettext.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,8 @@ extern int use_gettext_poison(void);
4444

4545
static inline FORMAT_PRESERVING(1) const char *_(const char *msgid)
4646
{
47+
if (!*msgid)
48+
return "";
4749
return use_gettext_poison() ? "# GETTEXT POISON #" : gettext(msgid);
4850
}
4951

0 commit comments

Comments
 (0)