Mercurial > hg > nnchat
changeset 395:74d97581dc46
Rename variable and function, internal use only.
author | Matti Hamalainen <ccr@tnsp.org> |
---|---|
date | Thu, 24 May 2012 04:58:10 +0300 |
parents | cabf2233ea39 |
children | 07a46ca075ab |
files | libnnchat.c libnnchat.h |
diffstat | 2 files changed, 7 insertions(+), 7 deletions(-) [+] |
line wrap: on
line diff
--- a/libnnchat.c Thu May 24 04:57:37 2012 +0300 +++ b/libnnchat.c Thu May 24 04:58:10 2012 +0300 @@ -358,7 +358,7 @@ { if (conn != NULL) { - conn->got_ptr = conn->buf; + conn->ptr = conn->in_ptr = conn->buf; conn->got_bytes = conn->total_bytes = 0; } } @@ -390,7 +390,7 @@ } else if (FD_ISSET(conn->socket, &tmpfds)) { - conn->got_bytes = recv(conn->socket, conn->got_ptr, NN_CONNBUF_SIZE - conn->total_bytes, 0); + conn->got_bytes = recv(conn->socket, conn->in_ptr, NN_CONNBUF_SIZE - conn->total_bytes, 0); if (conn->got_bytes < 0) { conn->err = nn_get_socket_errno(); @@ -406,7 +406,7 @@ else { conn->total_bytes += conn->got_bytes; - conn->got_ptr += conn->got_bytes; + conn->in_ptr += conn->got_bytes; return 0; } } @@ -491,7 +491,7 @@ } -static int getHexDigit(const int c, const int shift) +static int nn_get_hexdigit(const int c, const int shift) { int i; @@ -546,9 +546,9 @@ s++; if (*s == '%') PUSHCHAR('%'); - else if ((c = getHexDigit(*s, 4)) >= 0) + else if ((c = nn_get_hexdigit(*s, 4)) >= 0) { - int i = getHexDigit(*(++s), 0); + int i = nn_get_hexdigit(*(++s), 0); if (i >= 0) { PUSHCHAR(c | i);