From 0da2df248ba5915630d04e7b7335bea409670cd6 Mon Sep 17 00:00:00 2001 From: Michael Widenius Date: Wed, 18 May 2011 00:47:56 +0300 Subject: Removed some alias warnings Fixed alias bug when compiling with gcc 4.2.4 that caused subselect.test to fail sql/item.cc: Removed alias warnings by changing type from char * to const char* sql/item.h: Removed alias warnings by changing type from char * to const char* sql/item_subselect.cc: Fixed alias bug when compiling with gcc 4.2.4 that caused subselect.test to fail sql/sql_string.h: Removed alias warnings by changing type from char * to const char* storage/heap/hp_test2.c: Removed SAFEMALLOC to get rid of compiler error Fixed test case as we can't anymore use heap_rlast() on a HASH key entry. --- storage/heap/hp_test2.c | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) (limited to 'storage/heap/hp_test2.c') diff --git a/storage/heap/hp_test2.c b/storage/heap/hp_test2.c index bf06cf03035..ba593f31cb0 100644 --- a/storage/heap/hp_test2.c +++ b/storage/heap/hp_test2.c @@ -21,9 +21,6 @@ #ifdef DBUG_OFF #undef DBUG_OFF #endif -#ifndef SAFEMALLOC -#define SAFEMALLOC -#endif #include "heapdef.h" /* Because of hp_find_block */ #include @@ -319,7 +316,8 @@ int main(int argc, char *argv[]) if (!silent) printf("- Read last key - delete - prev - prev - opt_delete - prev -> first\n"); - if (heap_rlast(file,record3,0)) goto err; + if (heap_rprev(file,record)) + goto err; if (heap_delete(file,record3)) goto err; key_check-=atoi((char*) record3); key1[atoi((char*) record+keyinfo[0].seg[0].start)]--; @@ -526,7 +524,7 @@ int main(int argc, char *argv[]) } ant=0; - for (error=heap_rlast(file,record,0) ; + for (error=heap_rprev(file,record) ; ! error ; error=heap_rprev(file,record)) { -- cgit v1.2.1