libxbps: xbps_fetch_error_string: return NULL on libfetch success.

This commit is contained in:
Juan RP 2011-11-11 00:30:01 +01:00
parent bbd83767c6
commit 756234e9c3

View File

@ -81,6 +81,9 @@ xbps_fetch_unset_cache_connection(void)
const char * const char *
xbps_fetch_error_string(void) xbps_fetch_error_string(void)
{ {
if (fetchLastErrCode == 0 || fetchLastErrCode == FETCH_OK)
return NULL;
return fetchLastErrString; return fetchLastErrString;
} }