fragment: only munge if sysroot_dir is actually set

on cygwin/msys2, it is possible for munging to be enabled for other types of munging (instead of sysroot)
feature/tap-sh
William Pitcock 2017-01-13 19:55:54 -06:00
parent 5b8e59f036
commit 7f6a185977
1 changed files with 1 additions and 1 deletions

View File

@ -95,7 +95,7 @@ pkgconf_fragment_munge(const pkgconf_client_t *client, char *buf, size_t buflen,
if (sysroot_dir == NULL) if (sysroot_dir == NULL)
sysroot_dir = pkgconf_tuple_find_global(client, "pc_sysrootdir"); sysroot_dir = pkgconf_tuple_find_global(client, "pc_sysrootdir");
if (pkgconf_fragment_should_munge(source, sysroot_dir)) if (sysroot_dir != NULL && pkgconf_fragment_should_munge(source, sysroot_dir))
pkgconf_strlcat(buf, sysroot_dir, buflen); pkgconf_strlcat(buf, sysroot_dir, buflen);
pkgconf_strlcat(buf, source, buflen); pkgconf_strlcat(buf, source, buflen);