diff options
author | unknown <jimw@mysql.com> | 2005-08-31 10:08:55 -0700 |
---|---|---|
committer | unknown <jimw@mysql.com> | 2005-08-31 10:08:55 -0700 |
commit | b34af8cde47ec0168b5878988b791cbc69dc65b4 (patch) | |
tree | c1f9152e88243517c07aabc96a903ee85dc2a24c /sql/examples | |
parent | 7b8ab0e1cff25108f3b044189db879fd39073290 (diff) | |
download | mariadb-git-b34af8cde47ec0168b5878988b791cbc69dc65b4.tar.gz |
Add test for madvise() being declared in C++ code, because it is not
on Solaris even though it is available, and declare it ourselves in
that case. (Bug #7156)
configure.in:
Add test for madvise() being declared when C++ compiler is used.
include/my_global.h:
Handle madvise() being available but not declared in C++
isam/extra.c:
Fix typo in define test
myisam/mi_extra.c:
Fix typo in define test
sql/examples/ha_tina.cc:
Test that we have madvise() before trying to call it.
Diffstat (limited to 'sql/examples')
-rw-r--r-- | sql/examples/ha_tina.cc | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/sql/examples/ha_tina.cc b/sql/examples/ha_tina.cc index 07e69bfac80..bbcdfb0dafb 100644 --- a/sql/examples/ha_tina.cc +++ b/sql/examples/ha_tina.cc @@ -608,7 +608,9 @@ int ha_tina::rnd_init(bool scan) current_position= next_position= 0; records= 0; chain_ptr= chain; +#ifdef HAVE_MADVISE (void)madvise(share->mapped_file,share->file_stat.st_size,MADV_SEQUENTIAL); +#endif DBUG_RETURN(0); } |