Loading ChangeLog +6 −0 Original line number Diff line number Diff line Loading @@ -58,6 +58,12 @@ Changes in version 0.2.0.16-alpha - 2008-01-?? but client versions are not. - Fix rare bug on REDIRECTSTREAM control command when called with no port set: it could erroneously report an error when none had happened. - Avoid bogus crash-prone, leak-prone tor_realloc when we're compressing large objects and find ourselves with more than 4k left over. Bugfix on 0.2.0. - Fix a small memory leak when setting up a hidden service. - Fix a few memory leaks that could in theory happen under bizarre error conditions. o Minor features (controller): - Get NS events working again. (Patch from tup) Loading src/common/torgzip.c +1 −1 Original line number Diff line number Diff line Loading @@ -139,7 +139,7 @@ tor_gzip_compress(char **out, size_t *out_len, *out_len = stream->total_out; if (stream->total_out > out_size + 4097) { /* If we're wasting more than 4k, don't. */ tor_realloc(*out, stream->total_out + 1); *out = tor_realloc(*out, stream->total_out + 1); } if (deflateEnd(stream)!=Z_OK) { log_warn(LD_BUG, "Error freeing gzip structures"); Loading src/common/tortls.c +1 −1 Original line number Diff line number Diff line Loading @@ -43,7 +43,7 @@ const char tortls_c_id[] = #include <string.h> // #define V2_HANDSHAKE_SERVER // #define V2_HANDSHAKE_CLIENT #define V2_HANDSHAKE_CLIENT /* Copied from or.h */ #define LEGAL_NICKNAME_CHARACTERS \ Loading src/or/config.c +3 −0 Original line number Diff line number Diff line Loading @@ -1153,6 +1153,8 @@ options_act(or_options_t *old_options) if (parse_redirect_line(sl, cl, &errmsg)<0) { log_warn(LD_CONFIG, "%s", errmsg); tor_free(errmsg); SMARTLIST_FOREACH(sl, exit_redirect_t *, er, tor_free(er)); smartlist_free(sl); return -1; } } Loading Loading @@ -2096,6 +2098,7 @@ list_torrc_options(void) smartlist_clear(lines); } } smartlist_free(lines); } /** Last value actually set by resolve_my_address. */ Loading src/or/control.c +2 −0 Original line number Diff line number Diff line Loading @@ -704,6 +704,7 @@ control_setconf_helper(control_connection_t *conn, uint32_t len, char *body, connection_write_str_to_buf("551 Couldn't parse string\r\n", conn); SMARTLIST_FOREACH(entries, char *, cp, tor_free(cp)); smartlist_free(entries); tor_free(key); return 0; } } Loading Loading @@ -1440,6 +1441,7 @@ getinfo_helper_dir(control_connection_t *control_conn, res = dirserv_get_routerdescs(descs, url, &msg); if (res) { log_warn(LD_CONTROL, "getinfo '%s': %s", question, msg); smartlist_free(descs); return -1; } SMARTLIST_FOREACH(descs, signed_descriptor_t *, sd, Loading Loading
ChangeLog +6 −0 Original line number Diff line number Diff line Loading @@ -58,6 +58,12 @@ Changes in version 0.2.0.16-alpha - 2008-01-?? but client versions are not. - Fix rare bug on REDIRECTSTREAM control command when called with no port set: it could erroneously report an error when none had happened. - Avoid bogus crash-prone, leak-prone tor_realloc when we're compressing large objects and find ourselves with more than 4k left over. Bugfix on 0.2.0. - Fix a small memory leak when setting up a hidden service. - Fix a few memory leaks that could in theory happen under bizarre error conditions. o Minor features (controller): - Get NS events working again. (Patch from tup) Loading
src/common/torgzip.c +1 −1 Original line number Diff line number Diff line Loading @@ -139,7 +139,7 @@ tor_gzip_compress(char **out, size_t *out_len, *out_len = stream->total_out; if (stream->total_out > out_size + 4097) { /* If we're wasting more than 4k, don't. */ tor_realloc(*out, stream->total_out + 1); *out = tor_realloc(*out, stream->total_out + 1); } if (deflateEnd(stream)!=Z_OK) { log_warn(LD_BUG, "Error freeing gzip structures"); Loading
src/common/tortls.c +1 −1 Original line number Diff line number Diff line Loading @@ -43,7 +43,7 @@ const char tortls_c_id[] = #include <string.h> // #define V2_HANDSHAKE_SERVER // #define V2_HANDSHAKE_CLIENT #define V2_HANDSHAKE_CLIENT /* Copied from or.h */ #define LEGAL_NICKNAME_CHARACTERS \ Loading
src/or/config.c +3 −0 Original line number Diff line number Diff line Loading @@ -1153,6 +1153,8 @@ options_act(or_options_t *old_options) if (parse_redirect_line(sl, cl, &errmsg)<0) { log_warn(LD_CONFIG, "%s", errmsg); tor_free(errmsg); SMARTLIST_FOREACH(sl, exit_redirect_t *, er, tor_free(er)); smartlist_free(sl); return -1; } } Loading Loading @@ -2096,6 +2098,7 @@ list_torrc_options(void) smartlist_clear(lines); } } smartlist_free(lines); } /** Last value actually set by resolve_my_address. */ Loading
src/or/control.c +2 −0 Original line number Diff line number Diff line Loading @@ -704,6 +704,7 @@ control_setconf_helper(control_connection_t *conn, uint32_t len, char *body, connection_write_str_to_buf("551 Couldn't parse string\r\n", conn); SMARTLIST_FOREACH(entries, char *, cp, tor_free(cp)); smartlist_free(entries); tor_free(key); return 0; } } Loading Loading @@ -1440,6 +1441,7 @@ getinfo_helper_dir(control_connection_t *control_conn, res = dirserv_get_routerdescs(descs, url, &msg); if (res) { log_warn(LD_CONTROL, "getinfo '%s': %s", question, msg); smartlist_free(descs); return -1; } SMARTLIST_FOREACH(descs, signed_descriptor_t *, sd, Loading