aboutsummaryrefslogtreecommitdiff
path: root/src/ui/file_load_entry.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/ui/file_load_entry.c')
-rw-r--r--src/ui/file_load_entry.c10
1 files changed, 8 insertions, 2 deletions
diff --git a/src/ui/file_load_entry.c b/src/ui/file_load_entry.c
index a722787..1c0f175 100644
--- a/src/ui/file_load_entry.c
+++ b/src/ui/file_load_entry.c
@@ -1,6 +1,6 @@
1/* 1/*
2 This file is part of GNUnet. 2 This file is part of GNUnet.
3 Copyright (C) 2022 GNUnet e.V. 3 Copyright (C) 2022--2024 GNUnet e.V.
4 4
5 GNUnet is free software: you can redistribute it and/or modify it 5 GNUnet is free software: you can redistribute it and/or modify it
6 under the terms of the GNU Affero General Public License as published 6 under the terms of the GNU Affero General Public License as published
@@ -30,8 +30,10 @@
30 30
31static void 31static void
32handle_cancel_button_click(GNUNET_UNUSED GtkButton *button, 32handle_cancel_button_click(GNUNET_UNUSED GtkButton *button,
33 gpointer user_data) 33 gpointer user_data)
34{ 34{
35 g_assert(user_data);
36
35 UI_FILE_LOAD_ENTRY_Handle* handle = (UI_FILE_LOAD_ENTRY_Handle*) user_data; 37 UI_FILE_LOAD_ENTRY_Handle* handle = (UI_FILE_LOAD_ENTRY_Handle*) user_data;
36 38
37 if (handle->chat) 39 if (handle->chat)
@@ -43,6 +45,8 @@ handle_cancel_button_click(GNUNET_UNUSED GtkButton *button,
43UI_FILE_LOAD_ENTRY_Handle* 45UI_FILE_LOAD_ENTRY_Handle*
44ui_file_load_entry_new(MESSENGER_Application *app) 46ui_file_load_entry_new(MESSENGER_Application *app)
45{ 47{
48 g_assert(app);
49
46 UI_FILE_LOAD_ENTRY_Handle* handle = g_malloc(sizeof(UI_FILE_LOAD_ENTRY_Handle)); 50 UI_FILE_LOAD_ENTRY_Handle* handle = g_malloc(sizeof(UI_FILE_LOAD_ENTRY_Handle));
47 51
48 handle->chat = NULL; 52 handle->chat = NULL;
@@ -84,6 +88,8 @@ ui_file_load_entry_new(MESSENGER_Application *app)
84void 88void
85ui_file_load_entry_delete(UI_FILE_LOAD_ENTRY_Handle *handle) 89ui_file_load_entry_delete(UI_FILE_LOAD_ENTRY_Handle *handle)
86{ 90{
91 g_assert(handle);
92
87 g_object_unref(handle->builder); 93 g_object_unref(handle->builder);
88 94
89 g_free(handle); 95 g_free(handle);