Free memory allocated with malloc()

This commit is contained in:
2024-03-20 00:02:41 -04:00
parent 1641cef13b
commit b6439bf7d5
4 changed files with 5 additions and 1 deletions

View File

@@ -312,7 +312,7 @@ int main(int argc, char** argv) {
display_and_exit_raygui(std::string(inv.what()) + "\nClosing game...", 2);
return -1;
}
free(code_text);
free(code_text);
}
}
@@ -392,6 +392,7 @@ int main(int argc, char** argv) {
/* If the response is NULL, that means it timed-out. In this case, there's no value to print */
std::cout << "NOTHING RECEIVED" << std::endl;
}
free(response_array);
}
/* Check to see if peer has quit the game */