]> de.git.xonotic.org Git - xonotic/darkplaces.git/commitdiff
fix strncmp to check for 3 parameters not 1
authorhavoc <havoc@d7cf8633-e32d-0410-b094-e92efae38249>
Sun, 17 Jun 2007 08:48:08 +0000 (08:48 +0000)
committerhavoc <havoc@d7cf8633-e32d-0410-b094-e92efae38249>
Sun, 17 Jun 2007 08:48:08 +0000 (08:48 +0000)
git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@7443 d7cf8633-e32d-0410-b094-e92efae38249

prvm_cmds.c

index 936b4d83bf8df3fd89006e844b50eebf7bb3ad43..828d5c86894c7448d5b684434aceacf0e3ea9131 100644 (file)
@@ -3799,7 +3799,7 @@ void VM_chr2str (void)
 void VM_strncmp (void)
 {
        const char *s1, *s2;
-       VM_SAFEPARMCOUNT(1, VM_strncmp);
+       VM_SAFEPARMCOUNT(3, VM_strncmp);
        s1 = PRVM_G_STRING(OFS_PARM0);
        s2 = PRVM_G_STRING(OFS_PARM1);
        PRVM_G_FLOAT(OFS_RETURN) = strncmp(s1, s2, (size_t)PRVM_G_FLOAT(OFS_PARM2));