ports/shells/ksh93/files/patch-src_lib_libast_sfio_sfseek.c
Cy Schubert 1b4fbb7092 AT&T AST (att/ast) on github has rewound their repo back to ksh93u+. See
https://github.com/att/ast/issues/1464 and
https://github.com/att/ast/issues/1466.

The reason for the rewind back to 93u+ instead of 93v- was that it was an
abandoned unstable buggy unfinished beta. A full explanation of this can be
found here, https://github.com/att/ast/issues/1466#issuecomment-589942449.

The version number is reverted back to 93u and an EPOCH bump, though not
needed, documents this siesmic shift.
2020-02-22 22:38:35 +00:00

25 lines
661 B
C

--- src/lib/libast/sfio/sfseek.c.orig 2020-02-08 10:39:38.000000000 -0800
+++ src/lib/libast/sfio/sfseek.c 2020-02-09 20:01:11.420655000 -0800
@@ -204,18 +204,9 @@
#ifdef MAP_TYPE
if(f->bits&SF_MMAP)
{ /* if mmap is not great, stop mmaping if moving around too much */
-#if _mmap_worthy < 2
- if((f->next - f->data) < ((f->endb - f->data)/4) )
- { SFSETBUF(f,(Void_t*)f->tiny,(size_t)SF_UNBOUND);
- hardseek = 1; /* this forces a hard seek below */
- }
- else
-#endif
- { /* for mmap, f->here can be virtual except for hardseek */
- newpos(f,p);
- if(!hardseek)
- goto done;
- }
+ newpos(f,p);
+ if(!hardseek)
+ goto done;
}
#endif