From: Chad Versace Date: Fri, 15 Apr 2016 19:33:41 +0000 (-0700) Subject: util: Fix warning of invalid return value X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=4a80890177015fef792ac2e069452fe340f36769;p=mesa.git util: Fix warning of invalid return value _mesa_libgcrypt_init() returns NULL, but its return type is void. Reviewed-by: Mark Janes --- diff --git a/src/util/mesa-sha1.c b/src/util/mesa-sha1.c index ca6b89bb2c7..b6a192f4dab 100644 --- a/src/util/mesa-sha1.c +++ b/src/util/mesa-sha1.c @@ -180,7 +180,8 @@ _mesa_sha1_final(struct mesa_sha1 *ctx, unsigned char result[20]) static void _mesa_libgcrypt_init(void) { if (!gcry_check_version(NULL)) - return NULL; + return; + gcry_control(GCRYCTL_DISABLE_SECMEM, 0); gcry_control(GCRYCTL_INITIALIZATION_FINISHED, 0); }