aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--contrib/pgcrypto/crypt-md5.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/contrib/pgcrypto/crypt-md5.c b/contrib/pgcrypto/crypt-md5.c
index d38721a1010..33f93847a42 100644
--- a/contrib/pgcrypto/crypt-md5.c
+++ b/contrib/pgcrypto/crypt-md5.c
@@ -33,11 +33,11 @@ _crypt_to64(char *s, unsigned long v, int n)
char *
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,
+ static const char *magic = "$1$"; /* This string is magic for this
+ * algorithm. Having it this way, we
+ * can get better later on */
+ char *p;
+ const char *sp,
*ep;
unsigned char final[MD5_SIZE];
int sl,
@@ -81,7 +81,7 @@ px_crypt_md5(const char *pw, const char *salt, char *passwd, unsigned dstlen)
px_md_update(ctx, (const uint8 *) pw, strlen(pw));
/* Then our magic string */
- px_md_update(ctx, (uint8 *) magic, strlen(magic));
+ px_md_update(ctx, (const uint8 *) magic, strlen(magic));
/* Then the raw salt */
px_md_update(ctx, (const uint8 *) sp, sl);