diff options
-rw-r--r-- | perl.h | 4 | ||||
-rw-r--r-- | perlio.c | 2 |
2 files changed, 5 insertions, 1 deletions
@@ -1180,6 +1180,10 @@ EXTERN_C char *crypt(const char *, const char *); EXTERN_C char **environ; #endif +#if defined(__OpenBSD__) && defined(__cplusplus) +EXTERN_C char **environ; +#endif + #if defined(__CYGWIN__) && defined(__cplusplus) EXTERN_C char *crypt(const char *, const char *); #endif @@ -4627,7 +4627,7 @@ PerlIOMmap_map(pTHX_ PerlIO *f) } posn = (b->posn / PL_mmap_page_size) * PL_mmap_page_size; len = st.st_size - posn; - m->mptr = mmap(NULL, len, PROT_READ, MAP_SHARED, fd, posn); + m->mptr = (Mmap_t)mmap(NULL, len, PROT_READ, MAP_SHARED, fd, posn); if (m->mptr && m->mptr != (Mmap_t) - 1) { #if 0 && defined(HAS_MADVISE) && defined(MADV_SEQUENTIAL) madvise(m->mptr, len, MADV_SEQUENTIAL); |