mirror of
https://gitlab.freedesktop.org/pkg-config/pkg-config.git
synced 2026-04-21 08:50:40 +02:00
Don't append NULL when a variable doesn't exist
This caused a glib warning when the following was encountered in
xml2po.pc (and PYTHON_PREFIX wasn't defined):
modesdir=${PYTHON_PREFIX}/lib/python2.7/site-packages/xml2po
This commit is contained in:
parent
d97db4fae4
commit
c16453f955
1 changed files with 2 additions and 1 deletions
3
parse.c
3
parse.c
|
|
@ -206,7 +206,8 @@ trim_and_sub (Package *pkg, const char *str, const char *path)
|
|||
|
||||
g_free (varname);
|
||||
|
||||
g_string_append (subst, varval);
|
||||
if (varval)
|
||||
g_string_append (subst, varval);
|
||||
g_free (varval);
|
||||
}
|
||||
else
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue