summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/main.c12
1 files changed, 9 insertions, 3 deletions
diff --git a/src/main.c b/src/main.c
index b6793c6..15ea208 100644
--- a/src/main.c
+++ b/src/main.c
@@ -50,6 +50,9 @@ get_server_ctx_from_msg (SoupMessage *msg,
ctx = g_hash_table_lookup (ctx_table, soup_uri_get_path (uri));
soup_uri_free (uri);
+ if (!ctx)
+ g_critical ("No matching context found for msg!\n");
+
return ctx;
}
@@ -204,15 +207,18 @@ stream_finished_cb (SoupMessage *msg,
{
gboolean ret;
- g_print ("Stream finished/aborted, sending EOS...\n");
+ g_print ("Stream finished/aborted, queueing EOS... ");
ctx->request_finished = TRUE;
/* Incoming stream has ended */
g_signal_emit_by_name (ctx->appsrc, "end-of-stream", &ret);
- if (!ret)
- g_printerr ("Unable to emit end-of-stream after an aborted stream\n");
+ if (ret != GST_FLOW_OK)
+ g_printerr ("\nUnable to emit end-of-stream after an aborted stream\n");
+ else
+ g_print ("Done.\n");
}
+/* This is called when the entire request body has been read */
static void
handle_request_cb (SoupServer *server,
SoupMessage *msg,