Index: uspace/lib/http/src/receive-buffer.c
===================================================================
--- uspace/lib/http/src/receive-buffer.c	(revision cde999aca79219e8751af76502001a86d411d176)
+++ uspace/lib/http/src/receive-buffer.c	(revision b7fd2a02e4161f4edd38548e7f8456b8021549be)
@@ -43,5 +43,5 @@
 #include <http/receive-buffer.h>
 
-int recv_buffer_init(receive_buffer_t *rb, size_t buffer_size,
+errno_t recv_buffer_init(receive_buffer_t *rb, size_t buffer_size,
     receive_func_t receive, void *client_data)
 {
@@ -61,5 +61,5 @@
 }
 
-static int dummy_receive(void *unused, void *buf, size_t buf_size,
+static errno_t dummy_receive(void *unused, void *buf, size_t buf_size,
     size_t *nrecv)
 {
@@ -68,7 +68,7 @@
 }
 
-int recv_buffer_init_const(receive_buffer_t *rb, void *buf, size_t size)
-{
-	int rc = recv_buffer_init(rb, size, dummy_receive, NULL);
+errno_t recv_buffer_init_const(receive_buffer_t *rb, void *buf, size_t size)
+{
+	errno_t rc = recv_buffer_init(rb, size, dummy_receive, NULL);
 	if (rc != EOK)
 		return rc;
@@ -107,5 +107,5 @@
 }
 
-int recv_cut(receive_buffer_t *rb, receive_buffer_mark_t *a, receive_buffer_mark_t *b, void **out_buf, size_t *out_size)
+errno_t recv_cut(receive_buffer_t *rb, receive_buffer_mark_t *a, receive_buffer_mark_t *b, void **out_buf, size_t *out_size)
 {
 	if (a->offset > b->offset)
@@ -123,5 +123,5 @@
 }
 
-int recv_cut_str(receive_buffer_t *rb, receive_buffer_mark_t *a, receive_buffer_mark_t *b, char **out_buf)
+errno_t recv_cut_str(receive_buffer_t *rb, receive_buffer_mark_t *a, receive_buffer_mark_t *b, char **out_buf)
 {
 	if (a->offset > b->offset)
@@ -147,5 +147,5 @@
 
 /** Receive one character (with buffering) */
-int recv_char(receive_buffer_t *rb, char *c, bool consume)
+errno_t recv_char(receive_buffer_t *rb, char *c, bool consume)
 {
 	if (rb->out == rb->in) {
@@ -170,5 +170,5 @@
 		
 		size_t nrecv;
-		int rc = rb->receive(rb->client_data, rb->buffer + rb->in, free, &nrecv);
+		errno_t rc = rb->receive(rb->client_data, rb->buffer + rb->in, free, &nrecv);
 		if (rc != EOK)
 			return rc;
@@ -183,5 +183,5 @@
 }
 
-int recv_buffer(receive_buffer_t *rb, char *buf, size_t buf_size,
+errno_t recv_buffer(receive_buffer_t *rb, char *buf, size_t buf_size,
     size_t *nrecv)
 {
@@ -202,8 +202,8 @@
  * @return EOK or an error code
  */
-int recv_discard(receive_buffer_t *rb, char discard, size_t *ndisc)
+errno_t recv_discard(receive_buffer_t *rb, char discard, size_t *ndisc)
 {
 	char c = 0;
-	int rc = recv_char(rb, &c, false);
+	errno_t rc = recv_char(rb, &c, false);
 	if (rc != EOK)
 		return rc;
@@ -223,10 +223,10 @@
  * @return EOK or an error code
  */
-int recv_discard_str(receive_buffer_t *rb, const char *discard, size_t *ndisc)
+errno_t recv_discard_str(receive_buffer_t *rb, const char *discard, size_t *ndisc)
 {
 	size_t discarded = 0;
 	while (*discard) {
 		size_t nd;
-		int rc = recv_discard(rb, *discard, &nd);
+		errno_t rc = recv_discard(rb, *discard, &nd);
 		if (rc != EOK)
 			return rc;
@@ -241,9 +241,9 @@
 }
 
-int recv_while(receive_buffer_t *rb, char_class_func_t class)
+errno_t recv_while(receive_buffer_t *rb, char_class_func_t class)
 {
 	while (true) {
 		char c = 0;
-		int rc = recv_char(rb, &c, false);
+		errno_t rc = recv_char(rb, &c, false);
 		if (rc != EOK)
 			return rc;
@@ -266,8 +266,8 @@
  * @return EOK on success or an error code
  */
-int recv_eol(receive_buffer_t *rb, size_t *nrecv)
+errno_t recv_eol(receive_buffer_t *rb, size_t *nrecv)
 {
 	char c = 0;
-	int rc = recv_char(rb, &c, false);
+	errno_t rc = recv_char(rb, &c, false);
 	if (rc != EOK)
 		return rc;
@@ -292,5 +292,5 @@
 
 /* Receive a single line */
-int recv_line(receive_buffer_t *rb, char *line, size_t size, size_t *nrecv)
+errno_t recv_line(receive_buffer_t *rb, char *line, size_t size, size_t *nrecv)
 {
 	size_t written = 0;
@@ -299,5 +299,5 @@
 	while (written < size) {
 		char c = 0;
-		int rc = recv_char(rb, &c, true);
+		errno_t rc = recv_char(rb, &c, true);
 		if (rc != EOK)
 			return rc;
