[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
Re: [tor-bugs] #7479 [Core Tor/Tor]: Replace more linked lists with queue.h implementations
#7479: Replace more linked lists with queue.h implementations
----------------------------------------------+----------------------------
Reporter: nickm | Owner:
Type: defect | Status: new
Priority: Low | Milestone: Tor:
| unspecified
Component: Core Tor/Tor | Version:
Severity: Normal | Resolution:
Keywords: tor-relay refactoring easy intro | Actual Points:
Parent ID: | Points:
Reviewer: | Sponsor:
----------------------------------------------+----------------------------
Comment (by nickm):
Replying to [comment:4 arma]:
> Replying to [comment:3 nickm]:
> > Sounds like a double-linked list might work there then.
>
> If we're ok walking to the end of the list each time we need to interact
with the end (which is a big part of what we do with cpaths), sure.
The BSD TAILQ_* type is exactly what one wants. It's a doubly-linked list
with a head pointer to the first and to the last. See src/ext/tor_queue.h
--
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/7479#comment:5>
Tor Bug Tracker & Wiki <https://trac.torproject.org/>
The Tor Project: anonymity online
_______________________________________________
tor-bugs mailing list
tor-bugs@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-bugs