aboutsummaryrefslogtreecommitdiff
path: root/src/lib/about.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib/about.c')
-rw-r--r--src/lib/about.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/src/lib/about.c b/src/lib/about.c
index 6e2b80f1..2d643033 100644
--- a/src/lib/about.c
+++ b/src/lib/about.c
@@ -65,12 +65,20 @@ GNUNET_GTK_about_window_realized (GtkWidget *widget, gpointer user_data)
65 GtkBuilder *builder = GTK_BUILDER (user_data); 65 GtkBuilder *builder = GTK_BUILDER (user_data);
66 GtkTextBuffer *license_contents; 66 GtkTextBuffer *license_contents;
67 gchar *license = NULL; 67 gchar *license = NULL;
68 const char *path;
69 char *license_path = NULL;
68 license_contents = GTK_TEXT_BUFFER (gtk_builder_get_object (builder, "license_contents")); 70 license_contents = GTK_TEXT_BUFFER (gtk_builder_get_object (builder, "license_contents"));
69 if (g_file_get_contents ("COPYING", &license, NULL, NULL) && license != NULL) 71 path = GNUNET_OS_installation_get_path (GNUNET_OS_IPK_DOCDIR);
72 if (path != NULL)
73 GNUNET_asprintf (&license_path, "%s%s", path, "COPYING");
74 else
75 license_path = GNUNET_strdup ("COPYING");
76 if (g_file_get_contents (license_path, &license, NULL, NULL) && license != NULL)
70 { 77 {
71 gtk_text_buffer_set_text (license_contents, license, -1); 78 gtk_text_buffer_set_text (license_contents, license, -1);
72 g_free (license); 79 g_free (license);
73 } 80 }
81 GNUNET_free_non_null (license_path);
74} 82}
75 83
76G_MODULE_EXPORT void 84G_MODULE_EXPORT void