From: Michael Schroeder Date: Tue, 30 Jan 2018 12:57:00 +0000 (+0100) Subject: Allow pool_error to be called with no pool X-Git-Tag: 0.6.31~6 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=4ed938e77f09c69c832f20f72cdf4fb4fea9af19;p=thirdparty%2Flibsolv.git Allow pool_error to be called with no pool In that case we just return with the specified value and don't log anything. --- diff --git a/src/pool.c b/src/pool.c index 1d9eadc0..ba5e799c 100644 --- a/src/pool.c +++ b/src/pool.c @@ -1517,6 +1517,9 @@ pool_error(Pool *pool, int ret, const char *format, ...) { va_list args; int l; + + if (!pool) + return ret; va_start(args, format); if (!pool->errstr) {