mirror of
git://git.code.sf.net/p/cdesktopenv/code
synced 2025-03-09 15:50:02 +00:00
libast: sfmode: tweak for 64-bit (Solaris 140-MAP_TYPE_64_Bits)
This upstreams a Solaris patch: https://github.com/oracle/solaris-userland/blob/master/components/ksh93/patches/140-MAP_TYPE_64_Bits.patch src/lib/libast/sfio/sfmode.c: _sfmode(): - Do not turn off mmap on 64-bit systems.
This commit is contained in:
parent
aa7713c2a9
commit
37637ab6b4
1 changed files with 1 additions and 1 deletions
|
@ -404,7 +404,7 @@ reg int local; /* a local call */
|
||||||
|
|
||||||
if(f->mode&SF_GETR)
|
if(f->mode&SF_GETR)
|
||||||
{ f->mode &= ~SF_GETR;
|
{ f->mode &= ~SF_GETR;
|
||||||
#ifdef MAP_TYPE
|
#if defined(MAP_TYPE) && (_ptr_bits < 64)
|
||||||
if((f->bits&SF_MMAP) && (f->tiny[0] += 1) >= (4*SF_NMAP) )
|
if((f->bits&SF_MMAP) && (f->tiny[0] += 1) >= (4*SF_NMAP) )
|
||||||
{ /* turn off mmap to avoid page faulting */
|
{ /* turn off mmap to avoid page faulting */
|
||||||
sfsetbuf(f,(Void_t*)f->tiny,(size_t)SF_UNBOUND);
|
sfsetbuf(f,(Void_t*)f->tiny,(size_t)SF_UNBOUND);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue