Hi, When reviewing patch [1], I find that the static class specifier is unnecessary for the variables sp and ep in the function px_crypt_md5().
diff --git a/contrib/pgcrypto/crypt-md5.c b/contrib/pgcrypto/crypt-md5.c index d38721a1010..3d17b2340fe 100644 --- a/contrib/pgcrypto/crypt-md5.c +++ b/contrib/pgcrypto/crypt-md5.c @@ -36,8 +36,8 @@ px_crypt_md5(const char *pw, const char *salt, char *passwd, unsigned dstlen) static char *magic = "$1$"; /* This string is magic for this algorithm. * Having it this way, we can get better later * on */ - static char *p; - static const char *sp, + char *p; + const char *sp, *ep; unsigned char final[MD5_SIZE]; int sl,
I also find that FreeBSD removed this specifier in [2]. Should we remove this? [1] https://www.postgresql.org/message-id/c763235a2757e2f5f9e3e27268b9028349cef659.camel%40oopsware.de [2] https://reviews.freebsd.org/D7306 -- Regrads, Japin Li