refactor: replace malloc with g_new0 in many occasions

This commit is contained in:
Michael Vetter
2026-02-27 00:38:28 +01:00
parent de5949e8eb
commit 373ec4a7e3
19 changed files with 56 additions and 56 deletions

View File

@@ -4891,7 +4891,7 @@ cmd_sendfile(ProfWin* window, const char* const command, gchar** args)
#endif
}
HTTPUpload* upload = malloc(sizeof(HTTPUpload));
HTTPUpload* upload = g_new0(HTTPUpload, 1);
if (!upload) {
cons_show_error("Memory allocation failed.");
if (fh) {