summaryrefslogtreecommitdiff
path: root/src/or/test.c
diff options
context:
space:
mode:
authorRoger Dingledine <arma@torproject.org>2006-07-06 02:44:07 +0000
committerRoger Dingledine <arma@torproject.org>2006-07-06 02:44:07 +0000
commitfad85f173a6a271af5ebbebffb778426febbce61 (patch)
treeb0063651a95606839d164d8dbfbc47936f179114 /src/or/test.c
parent3c4205c8724f6eb01dedc1ff6bbdd7f756320a4d (diff)
downloadtor-fad85f173a6a271af5ebbebffb778426febbce61.tar.gz
tor-fad85f173a6a271af5ebbebffb778426febbce61.zip
when an exit node gets a malformed begin cell, don't complain to
the node operator, since he can't do anything about it. svn:r6733
Diffstat (limited to 'src/or/test.c')
-rw-r--r--src/or/test.c11
1 files changed, 6 insertions, 5 deletions
diff --git a/src/or/test.c b/src/or/test.c
index bb13e25176..e7c460ba84 100644
--- a/src/or/test.c
+++ b/src/or/test.c
@@ -807,27 +807,28 @@ test_util(void)
/* Test parse_addr_port */
cp = NULL; u32 = 3; u16 = 3;
- test_assert(!parse_addr_port("1.2.3.4", &cp, &u32, &u16));
+ test_assert(!parse_addr_port(LOG_WARN, "1.2.3.4", &cp, &u32, &u16));
test_streq(cp, "1.2.3.4");
test_eq(u32, 0x01020304u);
test_eq(u16, 0);
tor_free(cp);
- test_assert(!parse_addr_port("4.3.2.1:99", &cp, &u32, &u16));
+ test_assert(!parse_addr_port(LOG_WARN, "4.3.2.1:99", &cp, &u32, &u16));
test_streq(cp, "4.3.2.1");
test_eq(u32, 0x04030201u);
test_eq(u16, 99);
tor_free(cp);
- test_assert(!parse_addr_port("nonexistent.address:4040", &cp, NULL, &u16));
+ test_assert(!parse_addr_port(LOG_WARN, "nonexistent.address:4040",
+ &cp, NULL, &u16));
test_streq(cp, "nonexistent.address");
test_eq(u16, 4040);
tor_free(cp);
- test_assert(!parse_addr_port("localhost:9999", &cp, &u32, &u16));
+ test_assert(!parse_addr_port(LOG_WARN, "localhost:9999", &cp, &u32, &u16));
test_streq(cp, "localhost");
test_eq(u32, 0x7f000001u);
test_eq(u16, 9999);
tor_free(cp);
u32 = 3;
- test_assert(!parse_addr_port("localhost", NULL, &u32, &u16));
+ test_assert(!parse_addr_port(LOG_WARN, "localhost", NULL, &u32, &u16));
test_eq(cp, NULL);
test_eq(u32, 0x7f000001u);
test_eq(u16, 0);