diff options
author | Wilmer van der Gaast <wilmer@gaast.net> | 2012-11-10 23:52:21 +0000 |
---|---|---|
committer | Wilmer van der Gaast <wilmer@gaast.net> | 2012-11-10 23:52:21 +0000 |
commit | ddc2de54664ec25b95bbce997fbbb6a7104f1203 (patch) | |
tree | f1f76bf48e9e5ca4eeb6eaa0b84687253f0f78f3 /lib/http_client.c | |
parent | 8bd866f3d336cb695006bc48592cf7475139aa36 (diff) |
Very immature code for reading from the streaming API. It reads from a
fixed URL and tried to parse individual JSON objects. Not doing anything
useful with it.
Diffstat (limited to 'lib/http_client.c')
-rw-r--r-- | lib/http_client.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/http_client.c b/lib/http_client.c index 17e21a49..acbf230c 100644 --- a/lib/http_client.c +++ b/lib/http_client.c @@ -281,6 +281,7 @@ static gboolean http_incoming_data( gpointer data, int source, b_input_condition memcpy( req->sbuf + req->sblen, buffer, st ); req->bytes_read += st; req->sblen += st; + req->sbuf[req->sblen] = '\0'; req->reply_body = req->sbuf + pos; req->body_size = req->sblen - pos; } |