diff options
author | overcaffeinated <overcaffeinated@airmail.cc> | 2016-10-27 10:12:28 +0100 |
---|---|---|
committer | overcaffeinated <overcaffeinated@airmail.cc> | 2016-10-27 10:12:28 +0100 |
commit | b8b8b6b70e670cb735b43bc6b90150ab1ed4e2d1 (patch) | |
tree | 7b7576212ceb2c0f342120860cc6c68c4abdd206 /src/common/util.h | |
parent | 48d7b693022e911899f1798386a2f5e277512cb2 (diff) | |
download | tor-b8b8b6b70e670cb735b43bc6b90150ab1ed4e2d1.tar.gz tor-b8b8b6b70e670cb735b43bc6b90150ab1ed4e2d1.zip |
Add implementation of smartlist_add_strdup
Add smartlist_add_strdup(sl, string) - replaces the use of
smartlist_add(sl, tor_strdup(string)). Fixes bug 20048.
Diffstat (limited to 'src/common/util.h')
-rw-r--r-- | src/common/util.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/common/util.h b/src/common/util.h index 479fc8d610..37f4bed1cb 100644 --- a/src/common/util.h +++ b/src/common/util.h @@ -239,6 +239,7 @@ void smartlist_add_asprintf(struct smartlist_t *sl, const char *pattern, ...) void smartlist_add_vasprintf(struct smartlist_t *sl, const char *pattern, va_list args) CHECK_PRINTF(2, 0); +void smartlist_add_strdup(struct smartlist_t *sl, const char *string); /* Time helpers */ long tv_udiff(const struct timeval *start, const struct timeval *end); |