home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!ogicse!psgrain!neon!pail!servio!chrisp
- From: chrisp@slc.com (Chris Pinkham)
- Newsgroups: comp.sys.hp
- Subject: Re: getpagesize - Is there one?
- Keywords: system page size get
- Message-ID: <1992Nov18.205156.27477@slc.com>
- Date: 18 Nov 92 20:51:56 GMT
- Article-I.D.: slc.1992Nov18.205156.27477
- References: <1eb3ctINNgi8@loon.graphics.cornell.edu>
- Organization: Servio Corp, Beaverton Oregon, US
- Lines: 17
-
- > Is there an hp-ux s700 8.07 equvalent of Ultrix getpagesize() ?
-
- I can't find it. How about this:
-
- #include <stdio.h>
- #include <sys/pstat.h>
-
- int getpagesize() {
- struct pst_static pstatic;
- union pstun pst;
-
- pst.pst_static = &pstatic;
- if ((pstat(PSTAT_STATIC, pst, sizeof(pstatic), 0, 0)) == -1) {
- return(-1);
- }
- return (pstatic.page_size);
- }
-