summaryrefslogtreecommitdiff
path: root/src/common/backtrace.c
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2016-09-06 12:35:37 -0400
committerNick Mathewson <nickm@torproject.org>2016-09-06 12:35:37 -0400
commit5927ed8d3324c39fd8aa3d496d119b37b97a1d73 (patch)
tree60fd91a8aaeaf9406658402537b350f7813563b6 /src/common/backtrace.c
parent4e3f9c1f3af6292f30799f005f6df8f9c1bc7fee (diff)
downloadtor-5927ed8d3324c39fd8aa3d496d119b37b97a1d73.tar.gz
tor-5927ed8d3324c39fd8aa3d496d119b37b97a1d73.zip
checkSpace.pl now forbids more identifiers.
The functions it warns about are: assert, memcmp, strcat, strcpy, sprintf, malloc, free, realloc, strdup, strndup, calloc. Also, fix a few lingering instances of these in the code. Use other conventions to indicate _intended_ use of assert and malloc/realloc/etc.
Diffstat (limited to 'src/common/backtrace.c')
-rw-r--r--src/common/backtrace.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/common/backtrace.c b/src/common/backtrace.c
index 2841281927..81e04e94eb 100644
--- a/src/common/backtrace.c
+++ b/src/common/backtrace.c
@@ -117,7 +117,7 @@ log_backtrace(int severity, int domain, const char *msg)
for (i=0; i < depth; ++i) {
tor_log(severity, domain, " %s", symbols[i]);
}
- free(symbols);
+ raw_free(symbols);
done:
tor_mutex_release(&cb_buf_mutex);
@@ -190,7 +190,7 @@ install_bt_handler(void)
size_t depth = backtrace(cb_buf, MAX_DEPTH);
symbols = backtrace_symbols(cb_buf, (int) depth);
if (symbols)
- free(symbols);
+ raw_free(symbols);
}
return rv;