diff options
author | Nick Mathewson <nickm@torproject.org> | 2004-07-22 20:34:55 +0000 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2004-07-22 20:34:55 +0000 |
commit | d07d0a4e6b2380917f72c1cd3a63de665ee7da69 (patch) | |
tree | 8fe008a0ec424007fa51546da0ef70e0bd4dbf48 /src | |
parent | 33fe5e362fa7365ce1274486437a68c4b33d620e (diff) | |
download | tor-d07d0a4e6b2380917f72c1cd3a63de665ee7da69.tar.gz tor-d07d0a4e6b2380917f72c1cd3a63de665ee7da69.zip |
Add fingerprint to router format in tests
svn:r2106
Diffstat (limited to 'src')
-rw-r--r-- | src/or/test.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/or/test.c b/src/or/test.c index 48e7113c07..635ffb15a2 100644 --- a/src/or/test.c +++ b/src/or/test.c @@ -652,6 +652,7 @@ test_dir_format() { char buf[8192], buf2[8192]; char platform[256]; + char fingerprint[FINGERPRINT_LEN+1]; char *pk1_str = NULL, *pk2_str = NULL, *pk3_str = NULL, *cp; int pk1_str_len, pk2_str_len, pk3_str_len; routerinfo_t r1, r2; @@ -725,7 +726,10 @@ test_dir_format() strcat(buf2, get_uname()); strcat(buf2, "\n" "published 1970-01-01 00:00:00\n" - "opt uptime 0\n" + "opt fingerprint "); + crypto_pk_get_fingerprint(pk2, fingerprint); + strcat(buf2, fingerprint); + strcat(buf2, "\nopt uptime 0\n" /* XXX the "0" above is hardcoded, but even if we made it reflect * uptime, that still wouldn't make it right, because the two * descriptors might be made on different seconds... hm. */ |