]> granicus.if.org Git - php/commitdiff
- cleanup, no vc6 support in trunk
authorPierre Joye <pajoye@php.net>
Tue, 15 Jun 2010 13:50:14 +0000 (13:50 +0000)
committerPierre Joye <pajoye@php.net>
Tue, 15 Jun 2010 13:50:14 +0000 (13:50 +0000)
ext/standard/php_crypt_r.c

index 2fee5feb0ff9e5e07be7d4408db34dad1ba13f94..4872c4959961a76b5dc9cf67ca2971f38b344ef4 100644 (file)
@@ -210,19 +210,12 @@ char * php_md5_crypt_r(const char *pw, const char *salt, char *out) {
 
        memcpy(passwd, MD5_MAGIC, MD5_MAGIC_LEN);
 
-#if _MSC_VER >= 1500
        if (strncpy_s(passwd + MD5_MAGIC_LEN, MD5_HASH_MAX_LEN - MD5_MAGIC_LEN, sp, sl + 1) != 0) {
                goto _destroyCtx1;
        }
        passwd[MD5_MAGIC_LEN + sl] = '\0';
        strcat_s(passwd, MD5_HASH_MAX_LEN, "$");
-#else
-       /* VC6 version doesn't have strcat_s or strncpy_s */
-       if (strncpy(passwd + MD5_MAGIC_LEN, sp, sl + 1) < sl) {
-               goto _destroyCtx1;
-       }
-       strcat(passwd, "$");
-#endif
+
        dwHashLen = 16;
 
        /* Fetch the ctx hash value */