Fix a memory leak in NetworkClient

This commit is contained in:
k1-801 authored and Adam Honse committed 2021-04-25 16:55:15 -05:00
1 parent dd4865c3e0
commit 402423e338
1 file changed
+1 -3
+1 -3
View File
@@ -918,9 +918,7 @@ std::vector<std::string> * NetworkClient::ProcessReply_ProfileList(unsigned int
memcpy(&name_len, data, sizeof(unsigned short));
data_ptr += sizeof(unsigned short);
char * profile_name = new char[name_len];
memcpy(&profile_name, data, name_len);
std::string profile_name(data, name_len);
profile_list->push_back(profile_name);
data_ptr += name_len;