]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/commit - lib/libcrc32c.c
crypto: LLVMLinux: Remove VLAIS usage from libcrc32c.c
authorJan-Simon Möller <dl9pf@gmx.de>
Mon, 2 Jul 2012 10:54:28 +0000 (12:54 +0200)
committerBehan Webster <behanw@converseincode.com>
Tue, 14 Oct 2014 08:51:23 +0000 (10:51 +0200)
commitea0e0de69fc413aa80dbf1ec1fb9702ea1b6faca
treeeaf66f02ff3614bb87a60e1ce17b8125ef67dc82
parentffb32e973eb5105ec55e0bbf2e77a1ea4a7a123a
crypto: LLVMLinux: Remove VLAIS usage from libcrc32c.c

Replaced the use of a Variable Length Array In Struct (VLAIS) with a C99
compliant equivalent. This patch allocates the appropriate amount of memory
using a char array using the SHASH_DESC_ON_STACK macro.

The new code can be compiled with both gcc and clang.

Signed-off-by: Jan-Simon Möller <dl9pf@gmx.de>
Signed-off-by: Behan Webster <behanw@converseincode.com>
Reviewed-by: Mark Charlebois <charlebm@gmail.com>
Acked-by: Herbert Xu <herbert@gondor.apana.org.au>
Cc: pageexec@freemail.hu
Cc: "David S. Miller" <davem@davemloft.net>
lib/libcrc32c.c