summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSeonah Moon <seonah1.moon@samsung.com>2017-09-27 13:30:29 +0900
committerSeonah Moon <seonah1.moon@samsung.com>2017-09-27 13:35:05 +0900
commit24b970fdd61a08c6ee2a7adf5b3dafb1f5dfb0af (patch)
treee827dc33760b7f639ed9e4d2e94f0f1bfa4bd1e7
parent27b9891b9db1ab7b5b716ade9ac2614c4a2bb257 (diff)
downloadhttp-24b970fdd61a08c6ee2a7adf5b3dafb1f5dfb0af.tar.gz
http-24b970fdd61a08c6ee2a7adf5b3dafb1f5dfb0af.tar.bz2
http-24b970fdd61a08c6ee2a7adf5b3dafb1f5dfb0af.zip
Change-Id: I8aa9202429fafdbfee845fda9c7d516a37ea1590 Signed-off-by: Seonah Moon <seonah1.moon@samsung.com>
-rw-r--r--packaging/capi-network-http.spec2
-rw-r--r--src/http_response.c2
-rw-r--r--test/http_test.c2
3 files changed, 3 insertions, 3 deletions
diff --git a/packaging/capi-network-http.spec b/packaging/capi-network-http.spec
index 9a11214..0b3db89 100644
--- a/packaging/capi-network-http.spec
+++ b/packaging/capi-network-http.spec
@@ -1,6 +1,6 @@
Name: capi-network-http
Summary: Http Framework
-Version: 0.0.28
+Version: 0.0.29
Release: 0
Group: System/Network
License: Apache-2.0
diff --git a/src/http_response.c b/src/http_response.c
index 29671ef..af85481 100644
--- a/src/http_response.c
+++ b/src/http_response.c
@@ -38,7 +38,7 @@ void __parse_response_header(gchar *buffer, size_t written, gpointer user_data)
__http_transaction_h* transaction = (__http_transaction_h *)user_data;
__http_response_h*response = (__http_response_h *)transaction->response;
- gchar status_code[HTTP_STATUS_CODE_SIZE] = {0, };
+ gchar status_code[HTTP_STATUS_CODE_SIZE + 1] = {0, };
gchar* start = NULL;
gchar* end = NULL;
diff --git a/test/http_test.c b/test/http_test.c
index a0ca2eb..2142663 100644
--- a/test/http_test.c
+++ b/test/http_test.c
@@ -159,7 +159,7 @@ int _write_message_body(http_transaction_h transaction, const char *file_path)
FILE *fp;
size_t file_size;
size_t chunk_size = 50;
- char *buf = malloc(chunk_size);
+ char *buf = malloc(chunk_size + 1);
if (stat(file_path, &file_info) != 0) {
ERR("stat() is failed", -1);