Patch from Douglas Mencken <dougmencken@gmail.com>:
The issue is that MESSAGE tries to invoke catgets with NULL first
parameter, which is dereferenced inside catgets (Std C Library
function) without checking, from catgets.c source:
if (catalog->name_ptr[idx + 0] == (u_int32_t) set
&& catalog->name_ptr[idx + 1] == (u_int32_t) message)
On the other hand, there's a special value: -1 (cast to nl_catd),
which must be used instead of 0 (NULL) in the case when we are unable
to provide real catalog_desc, from catgets.c source:
/* Be generous if catalog which failed to be open is used. */
if (catalog_desc == (nl_catd) -1 || ++set <= 0 || message < 0)
return (char *) string;
|
||
|---|---|---|
| .. | ||
| admin | ||
| config | ||
| databases | ||
| doc | ||
| examples | ||
| imports/motif | ||
| include | ||
| lib | ||
| logs | ||
| osf | ||
| programs | ||
| util | ||
| .gitignore | ||
| BUGREPORT | ||
| CLOSEDBUGS | ||
| CONTRIBUTORS | ||
| COPYING | ||
| Imakefile | ||
| Makefile | ||
| OPENBUGS | ||
| README-2.1.10 | ||
| README-2.1.20 | ||
| README-2.1.30 | ||
| README-2.1.30.snapshot | ||
| ReleaseNotes.ps | ||
| ReleaseNotes.sgm | ||
| copyright | ||
| copyright.old | ||