Commit ec7a7ac2 authored by unknown's avatar unknown

Bug fix for bug #15843 "Added mmap support in myisam creates compile problem

on AIX 5.2"

Added dummy definition of MAP_NORESERVE for systems which doesn't provide it,
removed duplicates

my_sys.h:
  added definition for MAP_NORESERVE
  (for Irix and AIX systems)
sql_map.cc:
  removed definition of MAP_NORESERVE
mi_packrec.c:
  removed definition of MAP_NORESERVE and MMAP_PRIVATE


storage/myisam/mi_packrec.c:
  removed definition of MAP_NORESERVE and MMAP_PRIVATE
sql/sql_map.cc:
  removed definition of MAP_NORESERVE
include/my_sys.h:
  added definition for MAP_NORESERVE
  (for Irix and AIX systems)
parent 32279956
...@@ -820,6 +820,9 @@ my_bool my_gethwaddr(uchar *to); ...@@ -820,6 +820,9 @@ my_bool my_gethwaddr(uchar *to);
#ifndef MAP_NOSYNC #ifndef MAP_NOSYNC
#define MAP_NOSYNC 0 #define MAP_NOSYNC 0
#endif #endif
#ifndef MAP_NORESERVE
#define MAP_NORESERVE 0 /* For irix and AIX */
#endif
#ifdef HAVE_MMAP64 #ifdef HAVE_MMAP64
#define my_mmap(a,b,c,d,e,f) mmap64(a,b,c,d,e,f) #define my_mmap(a,b,c,d,e,f) mmap64(a,b,c,d,e,f)
......
...@@ -25,10 +25,6 @@ ...@@ -25,10 +25,6 @@
#include <sys/mman.h> #include <sys/mman.h>
#endif #endif
#ifndef MAP_NORESERVE
#define MAP_NORESERVE 0 // For IRIX
#endif
mapped_files::mapped_files(const my_string filename,byte *magic,uint magic_length) mapped_files::mapped_files(const my_string filename,byte *magic,uint magic_length)
{ {
#ifdef HAVE_MMAP #ifdef HAVE_MMAP
......
...@@ -1176,13 +1176,6 @@ static uint max_bit(register uint value) ...@@ -1176,13 +1176,6 @@ static uint max_bit(register uint value)
static int _mi_read_mempack_record(MI_INFO *info,my_off_t filepos,byte *buf); static int _mi_read_mempack_record(MI_INFO *info,my_off_t filepos,byte *buf);
static int _mi_read_rnd_mempack_record(MI_INFO*, byte *,my_off_t, my_bool); static int _mi_read_rnd_mempack_record(MI_INFO*, byte *,my_off_t, my_bool);
#ifndef MAP_NORESERVE
#define MAP_NORESERVE 0 /* For irix */
#endif
#ifndef MAP_FAILED
#define MAP_FAILED -1
#endif
my_bool _mi_memmap_file(MI_INFO *info) my_bool _mi_memmap_file(MI_INFO *info)
{ {
byte *file_map; byte *file_map;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment