More changes to make 5.0.3 compile on Windows
sql_map.cc: moved include of sys/stat outside of HAVE_SYS_MMAN_H define my_decimal.h: Added define for EMBEDDED_SERVER for call to string2my_decimal mi_packrec.c: removed cast to caddr_t myisam/mi_packrec.c: removed cast to caddr_t sql/my_decimal.h: Added define for EMBEDDED_SERVER for call to string2my_decimal sql/sql_map.cc: moved include of sys/stat outside of HAVE_SYS_MMAN_H define
This commit is contained in:
parent
fc79380e69
commit
5064f26354
@ -1231,7 +1231,7 @@ my_bool _mi_memmap_file(MI_INFO *info)
|
||||
|
||||
void _mi_unmap_file(MI_INFO *info)
|
||||
{
|
||||
VOID(my_munmap((caddr_t) info->s->file_map,
|
||||
VOID(my_munmap(info->s->file_map,
|
||||
(size_t) info->s->state.state.data_file_length+
|
||||
MEMMAP_EXTRA_MARGIN));
|
||||
}
|
||||
|
@ -244,8 +244,7 @@ int str2my_decimal(uint mask, const char *str, my_decimal *d, char **end)
|
||||
int str2my_decimal(uint mask, const char *from, uint length,
|
||||
CHARSET_INFO *charset, my_decimal *decimal_value);
|
||||
|
||||
|
||||
#ifdef MYSQL_SERVER
|
||||
#if defined(MYSQL_SERVER) || defined(EMBEDDED_LIBRARY)
|
||||
inline
|
||||
int string2my_decimal(uint mask, const String *str, my_decimal *d)
|
||||
{
|
||||
@ -253,7 +252,6 @@ int string2my_decimal(uint mask, const String *str, my_decimal *d)
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
inline
|
||||
int double2my_decimal(uint mask, double val, my_decimal *d)
|
||||
{
|
||||
|
@ -19,10 +19,11 @@
|
||||
#pragma implementation // gcc: Class implementation
|
||||
#endif
|
||||
|
||||
#include <sys/stat.h>
|
||||
|
||||
#include "mysql_priv.h"
|
||||
#ifdef HAVE_SYS_MMAN_H
|
||||
#include <sys/mman.h>
|
||||
#include <sys/stat.h>
|
||||
#endif
|
||||
|
||||
#ifndef MAP_NORESERVE
|
||||
@ -71,7 +72,7 @@ mapped_files::~mapped_files()
|
||||
#ifdef HAVE_MMAP
|
||||
if (file >= 0)
|
||||
{
|
||||
VOID(my_munmap((caddr_t) map,size));
|
||||
VOID(my_munmap(map,size));
|
||||
VOID(my_close(file,MYF(0)));
|
||||
file= -1; map=0;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user