Deleted Added
full compact
reverse.c (17833) reverse.c (21786)
1/*-
2 * Copyright (c) 1991, 1993
3 * The Regents of the University of California. All rights reserved.
4 *
5 * This code is derived from software contributed to Berkeley by
6 * Edward Sze-Tyan Wang.
7 *
8 * Redistribution and use in source and binary forms, with or without

--- 111 unchanged lines hidden (view full) ---

120
121 if (size > SIZE_T_MAX) {
122 errno = EFBIG;
123 ierr();
124 return;
125 }
126
127 if ((start = mmap(NULL, (size_t)size,
1/*-
2 * Copyright (c) 1991, 1993
3 * The Regents of the University of California. All rights reserved.
4 *
5 * This code is derived from software contributed to Berkeley by
6 * Edward Sze-Tyan Wang.
7 *
8 * Redistribution and use in source and binary forms, with or without

--- 111 unchanged lines hidden (view full) ---

120
121 if (size > SIZE_T_MAX) {
122 errno = EFBIG;
123 ierr();
124 return;
125 }
126
127 if ((start = mmap(NULL, (size_t)size,
128 PROT_READ, 0, fileno(fp), (off_t)0)) == (caddr_t)-1) {
128 PROT_READ, MAP_SHARED, fileno(fp), (off_t)0)) == MAP_FAILED) {
129 ierr();
130 return;
131 }
132 p = start + size - 1;
133
134 if (style == RBYTES && off < size)
135 size = off;
136

--- 129 unchanged lines hidden ---
129 ierr();
130 return;
131 }
132 p = start + size - 1;
133
134 if (style == RBYTES && off < size)
135 size = off;
136

--- 129 unchanged lines hidden ---