diff options
author | Nick Mathewson <nickm@torproject.org> | 2010-10-13 16:04:25 -0400 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2010-10-13 16:04:25 -0400 |
commit | 8c837db38f5b2015dd579de8d8df580f51d133bc (patch) | |
tree | 8a67afb20b2b998fa20b11c522acf1cb3cd634c6 /src/common | |
parent | cbda016bc5f588351900433835bca912efeb41c4 (diff) | |
parent | c9dece14ae7d9c14c17df6685f7504c23eb65899 (diff) | |
download | tor-8c837db38f5b2015dd579de8d8df580f51d133bc.tar tor-8c837db38f5b2015dd579de8d8df580f51d133bc.tar.gz |
Merge branch 'nodes'
Diffstat (limited to 'src/common')
-rw-r--r-- | src/common/address.c | 2 | ||||
-rw-r--r-- | src/common/address.h | 2 | ||||
-rw-r--r-- | src/common/container.c | 1 | ||||
-rw-r--r-- | src/common/util.c | 2 |
4 files changed, 3 insertions, 4 deletions
diff --git a/src/common/address.c b/src/common/address.c index c35f04c18..dcc32f1ae 100644 --- a/src/common/address.c +++ b/src/common/address.c @@ -311,7 +311,7 @@ tor_addr_is_internal(const tor_addr_t *addr, int for_listening) * brackets. */ const char * -tor_addr_to_str(char *dest, const tor_addr_t *addr, int len, int decorate) +tor_addr_to_str(char *dest, const tor_addr_t *addr, size_t len, int decorate) { const char *ptr; tor_assert(addr && dest); diff --git a/src/common/address.h b/src/common/address.h index 6116bb4b1..457532d0d 100644 --- a/src/common/address.h +++ b/src/common/address.h @@ -144,7 +144,7 @@ int tor_addr_port_parse(const char *s, tor_addr_t *addr_out, int tor_addr_parse_mask_ports(const char *s, tor_addr_t *addr_out, maskbits_t *mask_out, uint16_t *port_min_out, uint16_t *port_max_out); -const char * tor_addr_to_str(char *dest, const tor_addr_t *addr, int len, +const char * tor_addr_to_str(char *dest, const tor_addr_t *addr, size_t len, int decorate); int tor_addr_from_str(tor_addr_t *addr, const char *src); void tor_addr_copy(tor_addr_t *dest, const tor_addr_t *src); diff --git a/src/common/container.c b/src/common/container.c index 72f347034..0a95f33aa 100644 --- a/src/common/container.c +++ b/src/common/container.c @@ -268,7 +268,6 @@ smartlist_subtract(smartlist_t *sl1, const smartlist_t *sl2) /** Remove the <b>idx</b>th element of sl; if idx is not the last * element, swap the last element of sl into the <b>idx</b>th space. - * Return the old value of the <b>idx</b>th element. */ void smartlist_del(smartlist_t *sl, int idx) diff --git a/src/common/util.c b/src/common/util.c index e207ede88..7af89d917 100644 --- a/src/common/util.c +++ b/src/common/util.c @@ -934,7 +934,7 @@ esc_for_log(const char *s) char *result, *outp; size_t len = 3; if (!s) { - return tor_strdup(""); + return tor_strdup("(null)"); } for (cp = s; *cp; ++cp) { |