aboutsummaryrefslogtreecommitdiff
path: root/src/ui/new_contact.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/ui/new_contact.c')
-rw-r--r--src/ui/new_contact.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/ui/new_contact.c b/src/ui/new_contact.c
index 7d5d395..094dd67 100644
--- a/src/ui/new_contact.c
+++ b/src/ui/new_contact.c
@@ -49,18 +49,18 @@ handle_confirm_button_click(UNUSED GtkButton *button,
49 gchar *emsg = NULL; 49 gchar *emsg = NULL;
50 struct GNUNET_CHAT_Uri *uri = GNUNET_CHAT_uri_parse(id_text, &emsg); 50 struct GNUNET_CHAT_Uri *uri = GNUNET_CHAT_uri_parse(id_text, &emsg);
51 51
52 if (uri)
53 {
54 GNUNET_CHAT_lobby_join(app->chat.messenger.handle, uri);
55 GNUNET_CHAT_uri_destroy(uri);
56 }
57
58 if (emsg) 52 if (emsg)
59 { 53 {
60 printf("ERROR: %s\n", emsg); 54 g_printerr("ERROR: %s\n", emsg);
61 GNUNET_free(emsg); 55 GNUNET_free(emsg);
62 } 56 }
63 57
58 if (!uri)
59 goto close_dialog;
60
61 GNUNET_CHAT_lobby_join(app->chat.messenger.handle, uri);
62 GNUNET_CHAT_uri_destroy(uri);
63
64close_dialog: 64close_dialog:
65 gtk_window_close(GTK_WINDOW(app->ui.new_contact.dialog)); 65 gtk_window_close(GTK_WINDOW(app->ui.new_contact.dialog));
66} 66}