From: Bruno Haible Date: Sun, 23 Feb 2020 12:04:13 +0000 (+0100) Subject: crypto/arcfour: Use 'restrict'. X-Git-Tag: v1.0~4213 X-Git-Url: https://gitweb.git.savannah.gnu.org/gitweb/?a=commitdiff_plain;h=8f6c42bf9ab0aed1caca1368e5a4dc4f6eef2842;p=gnulib.git crypto/arcfour: Use 'restrict'. * lib/arcfour.h (arcfour_stream): Use 'restrict'. * modules/crypto/arcfour (configure.ac): Require AC_C_RESTRICT. --- diff --git a/ChangeLog b/ChangeLog index fc7190c20d..4da2852db3 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,9 @@ 2020-02-23 Bruno Haible + crypto/arcfour: Use 'restrict'. + * lib/arcfour.h (arcfour_stream): Use 'restrict'. + * modules/crypto/arcfour (configure.ac): Require AC_C_RESTRICT. + careadlinkat: Use 'restrict'. * lib/careadlinkat.h (careadlinkat): Use 'restrict'. * modules/careadlinkat (configure.ac): Require AC_C_RESTRICT. diff --git a/lib/arcfour.h b/lib/arcfour.h index b77df1a86e..cc4e37d594 100644 --- a/lib/arcfour.h +++ b/lib/arcfour.h @@ -37,7 +37,7 @@ typedef struct before this function is called. */ extern void arcfour_stream (arcfour_context * context, - const char *inbuf, char *outbuf, size_t length); + const char *inbuf, char *restrict outbuf, size_t length); /* Initialize CONTEXT using encryption KEY of KEYLEN bytes. KEY should be 40 bits (5 bytes) or longer. The KEY cannot be zero diff --git a/modules/crypto/arcfour b/modules/crypto/arcfour index 43d1345bc8..5e7736c920 100644 --- a/modules/crypto/arcfour +++ b/modules/crypto/arcfour @@ -9,6 +9,7 @@ Depends-on: stdint configure.ac: +AC_REQUIRE([AC_C_RESTRICT]) Makefile.am: lib_SOURCES += arcfour.c