]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/server/client.qc
Add strfree to reduce explicit use of strunzone/string_null
[xonotic/xonotic-data.pk3dir.git] / qcsrc / server / client.qc
index 08b85b4cef0747357f8fb32d447929706e842de8..663d16ed712f73d995025f28b98d1eba76c29627 100644 (file)
@@ -1352,8 +1352,8 @@ void ClientDisconnect(entity this)
 
     MUTATOR_CALLHOOK(ClientDisconnect, this);
 
 
     MUTATOR_CALLHOOK(ClientDisconnect, this);
 
-       if (CS(this).netname_previous) strunzone(CS(this).netname_previous); // needs to be before the CS entity is removed!
-       if (CS(this).weaponorder_byimpulse) strunzone(CS(this).weaponorder_byimpulse);
+       strfree(CS(this).netname_previous); // needs to be before the CS entity is removed!
+       strfree(CS(this).weaponorder_byimpulse);
        ClientState_detach(this);
 
        Portal_ClearAll(this);
        ClientState_detach(this);
 
        Portal_ClearAll(this);
@@ -1373,7 +1373,7 @@ void ClientDisconnect(entity this)
 
        bot_relinkplayerlist();
 
 
        bot_relinkplayerlist();
 
-       if (this.clientstatus) strunzone(this.clientstatus);
+       strfree(this.clientstatus);
        if (this.personal) delete(this.personal);
 
        this.playerid = 0;
        if (this.personal) delete(this.personal);
 
        this.playerid = 0;