Correct debugging messages to load/scan config

This commit is contained in:
Akira TAGOH 2017-11-16 11:37:36 +09:00
parent 676d8699cc
commit e73b5dcbf2
1 changed files with 4 additions and 4 deletions

View File

@ -3254,7 +3254,7 @@ FcConfigParseAndLoadFromMemoryInternal (FcConfig *config,
return FcFalse; return FcFalse;
len = strlen ((const char *) buffer); len = strlen ((const char *) buffer);
if (FcDebug () & FC_DBG_CONFIG) if (FcDebug () & FC_DBG_CONFIG)
printf ("\tLoading config file from %s\n", filename); printf ("\t%s config file from %s\n", load ? "Loading" : "Scanning", filename);
#ifdef ENABLE_LIBXML2 #ifdef ENABLE_LIBXML2
memset(&sax, 0, sizeof(sax)); memset(&sax, 0, sizeof(sax));
@ -3348,7 +3348,7 @@ bail2:
bail1: bail1:
if (error && complain) if (error && complain)
{ {
FcConfigMessage (0, FcSevereError, "Cannot load config file from %s", filename); FcConfigMessage (0, FcSevereError, "Cannot %s config file from %s", load ? "load" : "scan", filename);
return FcFalse; return FcFalse;
} }
return FcTrue; return FcTrue;
@ -3442,9 +3442,9 @@ bail0:
if (!ret && complain) if (!ret && complain)
{ {
if (name) if (name)
FcConfigMessage (0, FcSevereError, "Cannot load config file \"%s\"", name); FcConfigMessage (0, FcSevereError, "Cannot %s config file \"%s\"", load ? "load" : "scan", name);
else else
FcConfigMessage (0, FcSevereError, "Cannot load default config file"); FcConfigMessage (0, FcSevereError, "Cannot %s default config file", load ? "load" : "scan");
return FcFalse; return FcFalse;
} }
return FcTrue; return FcTrue;