summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--httpd.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/httpd.c b/httpd.c
index 49b6b1e..44f7109 100644
--- a/httpd.c
+++ b/httpd.c
@@ -53,7 +53,9 @@ static gboolean service_incoming(GSocketService *service,
* firstline to \0 (HTTP version) */
firstline[g_strv_length(firstline)-1] = '\0';
/* now join from the second string to get the request path */
- gchar *path = g_strjoinv(" ", firstline + 1);
+ gchar *path_escaped = g_strjoinv(" ", firstline + 1);
+ gchar *path = g_uri_unescape_string(path_escaped, NULL);
+ g_free(path_escaped);
g_strfreev(firstline);