From 80f2ffd875db95ac7cd03bec55a55690c8dbbf49 Mon Sep 17 00:00:00 2001 From: divverent Date: Wed, 4 Feb 2015 12:24:09 +0000 Subject: [PATCH 1/1] Fix check/write order in LHNETADDRESS_ToString. git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12143 d7cf8633-e32d-0410-b094-e92efae38249 --- lhnet.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lhnet.c b/lhnet.c index e3bc6b71..22982571 100644 --- a/lhnet.c +++ b/lhnet.c @@ -535,9 +535,9 @@ int LHNETADDRESS_ToString(const lhnetaddress_t *vaddress, char *string, int stri { lhnetaddressnative_t *address = (lhnetaddressnative_t *)vaddress; const unsigned char *a; - *string = 0; if (!address || !string || stringbuffersize < 1) return 0; + *string = 0; switch(address->addresstype) { default: -- 2.39.2