[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

Re: [tor-bugs] #29537 [Core Tor/Tor]: verify intptr_t round-trip through void *



#29537: verify intptr_t round-trip through void *
----------------------------------------+----------------------------------
 Reporter:  catalyst                    |          Owner:  (none)
     Type:  defect                      |         Status:  needs_revision
 Priority:  Medium                      |      Milestone:  Tor:
                                        |  0.4.1.x-final
Component:  Core Tor/Tor                |        Version:
 Severity:  Normal                      |     Resolution:
 Keywords:  portability technical-debt  |  Actual Points:
Parent ID:                              |         Points:
 Reviewer:  catalyst                    |        Sponsor:
----------------------------------------+----------------------------------
Changes (by catalyst):

 * status:  needs_review => needs_revision


Comment:

 Replying to [comment:7 rl1987]:
 > The following patch checks that we can put all valid values of `int` and
 `unsigned int` into `void *` and take them back. I suppose this is the
 ranges of number we care about in practice, as we may want to put signed
 and unsigned integer values into smartlist.
 >
 > https://github.com/torproject/tor/pull/724
 Thanks! That seems to exhaustively check the entire `int` and `unsigned
 int` ranges. It might be better to check some limited ranges, as nickm
 suggested above. That way we can catch some likely failures without taking
 too much time.

 The check doesn't have to be exhaustive because this is mostly an interim
 check until we stop doing this questionable thing in the future.

--
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/29537#comment:10>
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