From 54fae3a9ca0af5ab29cc02d9c91fc2c63c6bc872 Mon Sep 17 00:00:00 2001 From: Karen Arutyunov Date: Tue, 19 Sep 2017 21:04:30 +0300 Subject: Merge with latest original package version (master branch) --- libpkgconf/client.c | 23 ++++++----------------- 1 file changed, 6 insertions(+), 17 deletions(-) (limited to 'libpkgconf/client.c') diff --git a/libpkgconf/client.c b/libpkgconf/client.c index 6529dbd..f5f4717 100644 --- a/libpkgconf/client.c +++ b/libpkgconf/client.c @@ -13,8 +13,10 @@ * from the use of this software. */ +#include #include #include + /* * !doc * @@ -137,15 +139,12 @@ pkgconf_client_deinit(pkgconf_client_t *client) if (client->buildroot_dir != NULL) free(client->buildroot_dir); + pkgconf_path_free(&client->filter_libdirs); + pkgconf_path_free(&client->filter_includedirs); + pkgconf_tuple_free_global(client); pkgconf_path_free(&client->dir_list); pkgconf_cache_free(client); - - /* - * Fix the leak (issue #130 is reported). - */ - pkgconf_path_free(&client->filter_libdirs); - pkgconf_path_free(&client->filter_includedirs); } /* @@ -325,17 +324,7 @@ pkgconf_trace(const pkgconf_client_t *client, const char *filename, size_t linen size_t len; va_list va; - /* - * Workaround MinGW bug which doesn't recognize 'z' length modifier (despite - * the presence of -std=C99 option) which leads to crash (issue #125 is - * reported). - * - * This indeed is an issue with an outdated Windows run-time (msvcrt.dll) - * where MinGW delegates the function call. The modifier isn't mentioned in - * the documentation for Visual Studio 2015, but is for the later one. - */ - len = snprintf(errbuf, sizeof errbuf, "%s:%lu [%s]: ", - filename, (unsigned long)lineno, funcname); + len = snprintf(errbuf, sizeof errbuf, "%s:" SIZE_FMT_SPECIFIER " [%s]: ", filename, lineno, funcname); va_start(va, format); vsnprintf(errbuf + len, sizeof(errbuf) - len, format, va); -- cgit v1.1