[MPlayer-dev-eng] [PATCH] i18n fix for NetBSD

Frederick Bruckman fredb at immanent.net
Mon Feb 24 05:39:31 CET 2003


Hi,

NetBSD's bindtextdomain() clone is evidently deficient. It never
returns the second, dirname argument, but only the first on success
or NULL on any failure. Furthermore, it doesn't do anything different
if the second argument is NULL, so the call intended to query the
directory for the default domain was SEGV'ing.

For mplayer, I wrote a configure test (rather than use __NetBSD__),
with the idea that NetBSD might get this fixed eventually.

Note that it's not safe to use the return value of bindtextdomain()
in printf(), if it might be NULL. Does GNU's never return NULL?

Frederick
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: mplayer.diff
URL: <http://lists.mplayerhq.hu/pipermail/mplayer-dev-eng/attachments/20030223/015e2933/attachment.asc>


More information about the MPlayer-dev-eng mailing list