make servers not crash when they rep-hist-note circuits that don't start at them

svn:r1317
This commit is contained in:
Roger Dingledine 2004-03-20 20:21:20 +00:00
parent e5cf396285
commit 4f0bad280d

View File

@ -833,6 +833,14 @@ circuit_rep_hist_note_result(circuit_t *circ)
char *prev_nickname = NULL; char *prev_nickname = NULL;
routerinfo_t *router; routerinfo_t *router;
hop = circ->cpath; hop = circ->cpath;
if(!hop) {
/* XXX
* if !hop, then we're not the beginning of this circuit.
* for now, just forget about it. later, we should remember when
* extends-through-us failed, too.
*/
return;
}
if (options.ORPort) { if (options.ORPort) {
prev_nickname = options.Nickname; prev_nickname = options.Nickname;
} }