mirror of
https://git.jabber.space/devs/cproof.git
synced 2026-07-18 04:46:21 +00:00
Attempt to open file later to prevent potential resource leak
This commit is contained in:
@@ -4917,8 +4917,6 @@ cmd_sendfile(ProfWin* window, const char* const command, gchar** args)
|
||||
goto out;
|
||||
}
|
||||
|
||||
FILE* fh = fdopen(fd, "rb");
|
||||
|
||||
gboolean omemo_enabled = FALSE;
|
||||
gboolean sendfile_enabled = TRUE;
|
||||
|
||||
@@ -4952,6 +4950,8 @@ cmd_sendfile(ProfWin* window, const char* const command, gchar** args)
|
||||
goto out;
|
||||
}
|
||||
|
||||
FILE* fh = fdopen(fd, "rb");
|
||||
|
||||
if (omemo_enabled) {
|
||||
#ifdef HAVE_OMEMO
|
||||
char* err = NULL;
|
||||
|
||||
Reference in New Issue
Block a user