diff --git a/src/core/net-nonblock.c b/src/core/net-nonblock.c index 94c53e74..40e14605 100644 --- a/src/core/net-nonblock.c +++ b/src/core/net-nonblock.c @@ -63,7 +63,7 @@ int net_gethostbyname_nonblock(const char *addr, GIOChannel *pipe, /* child */ srand(time(NULL)); - memset(&rec, 0, sizeof(rec)); + memset(&rec, 0, sizeof(rec)); rec.error = net_gethostbyname(addr, &rec.ip4, &rec.ip6); if (rec.error == 0) { errorstr = NULL; @@ -79,7 +79,7 @@ int net_gethostbyname_nonblock(const char *addr, GIOChannel *pipe, rec.errlen = errorstr == NULL ? 0 : strlen(errorstr)+1; } - g_io_channel_write_block(pipe, &rec, sizeof(rec)); + g_io_channel_write_block(pipe, &rec, sizeof(rec)); if (rec.errlen != 0) g_io_channel_write_block(pipe, (void *) errorstr, rec.errlen); else { @@ -129,7 +129,7 @@ int net_gethostbyname_return(GIOChannel *pipe, RESOLVED_IP_REC *rec) /* read error string, if we can't read everything for some reason, just ignore it. */ rec->errorstr = g_malloc0(rec->errlen+1); - g_io_channel_read_block(pipe, rec->errorstr, rec->errlen); + g_io_channel_read_block(pipe, rec->errorstr, rec->errlen); } else { if (rec->host4) { g_io_channel_read_block(pipe, &len, sizeof(int)); @@ -170,7 +170,7 @@ static void simple_init(SIMPLE_THREAD_REC *rec, GIOChannel *handle) if (net_geterror(handle) != 0) { /* failed */ g_io_channel_shutdown(handle, TRUE, NULL); - g_io_channel_unref(handle); + g_io_channel_unref(handle); handle = NULL; } diff --git a/src/core/net-nonblock.h b/src/core/net-nonblock.h index af5968c8..10caa4d4 100644 --- a/src/core/net-nonblock.h +++ b/src/core/net-nonblock.h @@ -13,7 +13,7 @@ typedef struct { } RESOLVED_IP_REC; typedef struct { - int namelen; + int namelen; char *name; int error;