pkgsrc/chat/centericq/patches/patch-ai

31 lines
1 KiB
Text

$NetBSD: patch-ai,v 1.1 2005/09/19 19:42:11 adrianp Exp $
--- libgadu-0.1/http.c.orig 2005-01-23 13:22:37.000000000 +0000
+++ libgadu-0.1/http.c
@@ -264,7 +264,7 @@ int gg_http_watch_fd(struct gg_http *h)
}
if (h->state == GG_STATE_SENDING_QUERY) {
- unsigned int res;
+ int res;
if ((res = write(h->fd, h->query, strlen(h->query))) < 1) {
gg_debug(GG_DEBUG_MISC, "=> http, write() failed (len=%d, res=%d, errno=%d)\n", strlen(h->query), res, errno);
@@ -293,7 +293,7 @@ int gg_http_watch_fd(struct gg_http *h)
if (h->state == GG_STATE_READING_HEADER) {
char buf[1024], *tmp;
- unsigned int res;
+ int res;
if ((res = read(h->fd, buf, sizeof(buf))) == -1) {
gg_debug(GG_DEBUG_MISC, "=> http, reading header failed (errno=%d)\n", errno);
@@ -401,7 +401,7 @@ int gg_http_watch_fd(struct gg_http *h)
if (h->state == GG_STATE_READING_DATA) {
char buf[1024];
- unsigned int res;
+ int res;
if ((res = read(h->fd, buf, sizeof(buf))) == -1) {
gg_debug(GG_DEBUG_MISC, "=> http, reading body failed (errno=%d)\n", errno);