diff options
author | overcaffeinated <overcaffeinated@airmail.cc> | 2016-10-27 11:15:57 +0100 |
---|---|---|
committer | overcaffeinated <overcaffeinated@airmail.cc> | 2016-10-27 11:15:57 +0100 |
commit | e2577cce0c1a184e1278a49fb58382a995436d17 (patch) | |
tree | 2cc2960fbb5a075e47b159aedc12a2b9c701af7d /src/test/test_shared_random.c | |
parent | 265d5446faf2744569931bc54633684711bbf3ba (diff) | |
download | tor-e2577cce0c1a184e1278a49fb58382a995436d17.tar.gz tor-e2577cce0c1a184e1278a49fb58382a995436d17.zip |
Convert remaining files to smartlist_add_strdup
The coccinelle script produced errors with these test files so
convert the remaining cases of smartlist_add to
smartlist_add_strdup by hand.
Diffstat (limited to 'src/test/test_shared_random.c')
-rw-r--r-- | src/test/test_shared_random.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/test/test_shared_random.c b/src/test/test_shared_random.c index 056f199b94..d511f163e3 100644 --- a/src/test/test_shared_random.c +++ b/src/test/test_shared_random.c @@ -348,12 +348,12 @@ test_sr_commit(void *arg) /* We'll build a list of values from our commit that our parsing function * takes from a vote line and see if we can parse it correctly. */ { - smartlist_add(args, tor_strdup("1")); - smartlist_add(args, - tor_strdup(crypto_digest_algorithm_get_name(our_commit->alg))); - smartlist_add(args, tor_strdup(sr_commit_get_rsa_fpr(our_commit))); - smartlist_add(args, tor_strdup(our_commit->encoded_commit)); - smartlist_add(args, tor_strdup(our_commit->encoded_reveal)); + smartlist_add_strdup(args, "1"); + smartlist_add_strdup(args, + crypto_digest_algorithm_get_name(our_commit->alg)); + smartlist_add_strdup(args, sr_commit_get_rsa_fpr(our_commit)); + smartlist_add_strdup(args, our_commit->encoded_commit); + smartlist_add_strdup(args, our_commit->encoded_reveal); parsed_commit = sr_parse_commit(args); tt_assert(parsed_commit); /* That parsed commit should be _EXACTLY_ like our original commit (we |