diff options
author | Jarkko Hietaniemi <jhi@iki.fi> | 2000-11-05 21:28:39 +0000 |
---|---|---|
committer | Jarkko Hietaniemi <jhi@iki.fi> | 2000-11-05 21:28:39 +0000 |
commit | 3b1896ceb2dda52e5763627c0441c8157a0e486e (patch) | |
tree | bdb97805105a4079b4c37d5551f6b03a5f39bced | |
parent | 094536b8df8ad4aee348c9fcd079b9c9c49fd4ca (diff) | |
download | perl-3b1896ceb2dda52e5763627c0441c8157a0e486e.tar.gz |
Fake __FUNCTION__ for non-gcc builds, cast madvise()
first argument correctly.
p4raw-id: //depot/perl@7567
-rw-r--r-- | perlio.c | 5 |
1 files changed, 4 insertions, 1 deletions
@@ -100,6 +100,9 @@ PerlIO_init(void) #undef printf void PerlIO_debug(char *fmt,...) __attribute__((format(printf,1,2))); +#ifndef __GNUC__ +#define __FUNCTION__ "PerlIO_debug" +#endif void PerlIO_debug(char *fmt,...) @@ -1827,7 +1830,7 @@ PerlIOMmap_map(PerlIO *f) if (b->buf && b->buf != (STDCHAR *) -1) { #if defined(HAS_MADVISE) && defined(MADV_SEQUENTIAL) - madvise(b->buf, len, MADV_SEQUENTIAL); + madvise((Mmap_t)b->buf, len, MADV_SEQUENTIAL); #endif PerlIOBase(f)->flags = flags | PERLIO_F_RDBUF; b->end = b->buf+len; |