[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
[tor-bugs] #28981 [Core Tor]: Use HW_PHYSMEM in get_total_system_memory_impl
#28981: Use HW_PHYSMEM in get_total_system_memory_impl
--------------------+--------------------------
Reporter: kjak | Owner: (none)
Type: defect | Status: new
Priority: Medium | Component: Core Tor
Version: | Severity: Normal
Keywords: | Actual Points:
Parent ID: | Points:
Reviewer: | Sponsor:
--------------------+--------------------------
An upcoming PR will change `get_total_system_memory_impl` to use
`HW_PHYSMEM` instead of `HW_USERMEM` in the case where `HW_PHYSMEM` is
defined but some other methods are not available for getting the total
physical memory (one example: FreeBSD).
The code actually checks that `HW_PHYSMEM` is defined, and comments
reference `HW_PHYSMEM`, but `HW_USERMEM` is simply used instead.
For OpenBSD, NetBSD and OSX a 64-bit variant of `HW_PHYSMEM` is used when
available.
The same PR will also contain a commit to update/fix a couple of comments
in this same file. It will fix a typo in a comment and update another
comment which suggests that `HW_PHYSMEM64` is something only on OpenBSD
when NetBSD actually defines it as well.
--
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/28981>
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