]> git.rm.cloudns.org Git - xonotic/darkplaces.git/commitdiff
fix bug in Crypto_RetrieveLocalKey
authordivverent <divverent@d7cf8633-e32d-0410-b094-e92efae38249>
Thu, 22 Aug 2013 14:45:18 +0000 (14:45 +0000)
committerRudolf Polzer <divverent@xonotic.org>
Thu, 22 Aug 2013 14:55:41 +0000 (16:55 +0200)
From: Jan Behrens <zykure@web.de>

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@11998 d7cf8633-e32d-0410-b094-e92efae38249
::stable-branch::merge=fa69b3e45b5cf486826fcb9d5865159706c6f0e9

crypto.c

index 2baa5a97fd0d921a3962f346b47761bc8f6e9deb..622e5a392e5e4dc4f17f01c4599ea3c068db85a6 100644 (file)
--- a/crypto.c
+++ b/crypto.c
@@ -735,7 +735,7 @@ int Crypto_RetrieveLocalKey(int keyid, char *keyfp, size_t keyfplen, char *idfp,
                strlcpy(keyfp, pubkeys_fp64[keyid], keyfplen);
        if(idfp)
                if(pubkeys_havepriv[keyid])
-                       strlcpy(idfp, pubkeys_priv_fp64[keyid], keyfplen);
+                       strlcpy(idfp, pubkeys_priv_fp64[keyid], idfplen);
        if(issigned)
                *issigned = pubkeys_havesig[keyid];
        return 1;