summaryrefslogtreecommitdiff
path: root/locale/programs/locfile.c
diff options
context:
space:
mode:
Diffstat (limited to 'locale/programs/locfile.c')
-rw-r--r--locale/programs/locfile.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/locale/programs/locfile.c b/locale/programs/locfile.c
index 4dafaef19f..7c724e292f 100644
--- a/locale/programs/locfile.c
+++ b/locale/programs/locfile.c
@@ -51,7 +51,7 @@ locfile_read (struct localedef_t *result, struct charmap_t *charmap)
ldfile = lr_open (filename, locfile_hash);
if (ldfile == NULL)
{
- if (filename[0] != '/')
+ if (filename != NULL && filename[0] != '/')
{
char *i18npath = getenv ("I18NPATH");
if (i18npath != NULL && *i18npath != '\0')