Casts now unnecessary because of changed prototype.
[openssl.git] / apps / passwd.c
index 06155979f444a4b1d837bacc07ccf39a534f365c..6b8aafa1571128ca643af4138368d923f22efd3b 100644 (file)
@@ -323,13 +323,13 @@ static char *apr1_crypt(const char *passwd, const char *salt)
                MD5_CTX md2;
 
                MD5_Init(&md2);
-               MD5_Update(&md2, (i & 1) ? (unsigned char *) passwd : buf,
-                                (i & 1) ?               passwd_len : sizeof buf);
+               MD5_Update(&md2, (i & 1) ?     passwd : buf,
+                                (i & 1) ? passwd_len : sizeof buf);
                if (i % 3)
                        MD5_Update(&md2, salt_out, salt_len);
                if (i % 7)
                        MD5_Update(&md2, passwd, passwd_len);
-               MD5_Update(&md2, (i & 1) ?        buf : (unsigned char *) passwd,
+               MD5_Update(&md2, (i & 1) ?        buf : passwd,
                                 (i & 1) ? sizeof buf : passwd_len);
                MD5_Final(buf, &md2);
                }
@@ -346,7 +346,9 @@ static char *apr1_crypt(const char *passwd, const char *salt)
                        buf_perm[dest] = buf[source];
                buf_perm[14] = buf[5];
                buf_perm[15] = buf[11];
+#ifndef PEDANTIC /* Unfortunately, this generates a "no effect" warning */
                assert(16 == sizeof buf_perm);
+#endif
                
                output = salt_out + salt_len;
                assert(output == out_buf + strlen(out_buf));