diff options
author | Nick Mathewson <nickm@torproject.org> | 2017-03-07 11:13:40 -0500 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2017-03-16 14:38:28 -0400 |
commit | ab1fd85c999fe53af9503850c2642bd860e5b250 (patch) | |
tree | 4eef3abfc7ee373e638c99806a19385707f1ceb0 /src | |
parent | bb536a2e737b8d23f3514607bc3d6ff54ed19f0f (diff) | |
download | tor-ab1fd85c999fe53af9503850c2642bd860e5b250.tar.gz tor-ab1fd85c999fe53af9503850c2642bd860e5b250.zip |
Mark some warnings as bugs, and as (hopefully) unreachable.
Diffstat (limited to 'src')
-rw-r--r-- | src/or/consdiff.c | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/src/or/consdiff.c b/src/or/consdiff.c index a340cfd8f8..ed20e3b12f 100644 --- a/src/or/consdiff.c +++ b/src/or/consdiff.c @@ -801,20 +801,24 @@ consdiff_gen_diff(smartlist_t *cons1, smartlist_t *cons2, /* See that the script actually produces what we want. */ smartlist_t *ed_cons2 = apply_ed_diff(cons1, ed_diff); if (!ed_cons2) { - log_warn(LD_CONSDIFF, "Refusing to generate consensus diff because " + /* LCOV_EXCL_START -- impossible if diff generation is correct */ + log_warn(LD_BUG|LD_CONSDIFF, "Refusing to generate consensus diff because " "the generated ed diff could not be tested to successfully generate " "the target consensus."); goto error_cleanup; + /* LCOV_EXCL_STOP */ } int cons2_eq = smartlist_strings_eq(cons2, ed_cons2); SMARTLIST_FOREACH(ed_cons2, char*, line, tor_free(line)); smartlist_free(ed_cons2); if (!cons2_eq) { - log_warn(LD_CONSDIFF, "Refusing to generate consensus diff because " + /* LCOV_EXCL_START -- impossible if diff generation is correct. */ + log_warn(LD_BUG|LD_CONSDIFF, "Refusing to generate consensus diff because " "the generated ed diff did not generate the target consensus " "successfully when tested."); goto error_cleanup; + /* LCOV_EXCL_STOP */ } char cons1_hash_hex[HEX_DIGEST256_LEN+1]; @@ -832,7 +836,7 @@ consdiff_gen_diff(smartlist_t *cons1, smartlist_t *cons2, smartlist_free(ed_diff); return result; - error_cleanup: + error_cleanup: if (ed_diff) { smartlist_free(ed_diff); |