Why does syscall getpagesize()return int, not unsigned intor size_t?
getpagesize()
int
unsigned int
size_t
The prototype and short description below:
GETPAGESIZE(2) NAME getpagesize - get memory page size SYNOPSIS #include <unistd.h> int getpagesize(void);
intwas probably sufficient when it was invented. But this is no longer a problem because it has getpagesize()been removed from the POSIX standard since 2001 and has been replaced by sysconf(). You must use sysconf(_SC_PAGESIZE).
sysconf()
sysconf(_SC_PAGESIZE)
getpagesize() The return of int was one of the main reasons for removing it:
getpagesizegetpagesize() . sysconf (_SC_PAGE_SIZE) sysconf (_SC_PAGESIZE). , int, , . , . (, ). , . Application Application, Legacy - , sysconf().
getpagesize
getpagesize() . sysconf (_SC_PAGE_SIZE) sysconf (_SC_PAGESIZE). , int, , . , . (, ). , . Application Application, Legacy - , sysconf().
( ).
Source: https://habr.com/ru/post/1667968/More articles:Haskell: memoization - recursionHow to not plan missing periods - pythonAngular cli: production ready - angularΠ‘ΠΎΠ·Π΄Π°ΠΉΡΠ΅ ΠΊΠΎΠ½ΡΠ΅ΠΉΠ½Π΅Ρ (ΡΠΈΠΊΡΠΈΡΠΎΠ²Π°Π½Π½ΠΎΠ΅ ΡΠΎΠΎΡΠ½ΠΎΡΠ΅Π½ΠΈΠ΅ ΡΡΠΎΡΠΎΠ½) Π΄Π»Ρ ΠΏΠ΅ΠΉΠ·Π°ΠΆΠ½ΠΎΠΉ ΠΈΠ³ΡΡ SpriteKit, ΠΊΠΎΡΠΎΡΠ°Ρ ΠΌΠΎΠΆΠ΅Ρ Π²ΠΎΡΠΏΡΠΎΠΈΠ·Π²ΠΎΠ΄ΠΈΡΡΡΡ ΠΊΠ°ΠΊ Π½Π° iPhone, ΡΠ°ΠΊ ΠΈ Π½Π° iPad - iosApplication Requirements. Accessibility tests fail with a 200 OK error with "System.UriFormatException: invalid URI: URI format could not be determined." - azureMinimum version of Xcode to download to the app store - xcodeElement Removal Algorithm - c ++R - xlsx package - how to add cell color without changing the border - rSQL Server: pasting the output of multiple tables from a stored procedure into separate tables - sqlCognito Customizing Messages and Enabling User Attributes - springAll Articles