summaryrefslogtreecommitdiff
path: root/ndb
diff options
context:
space:
mode:
authorunknown <tomas@poseidon.(none)>2004-05-27 11:16:14 +0000
committerunknown <tomas@poseidon.(none)>2004-05-27 11:16:14 +0000
commitcc55f6934b726f08a5d078cc244e5461903c18f8 (patch)
treecd949077d4298ff8772df3faaf897a6c96787d3a /ndb
parentdaaa3def140628cb36db33d9803711eb05959f6b (diff)
downloadmariadb-git-cc55f6934b726f08a5d078cc244e5461903c18f8.tar.gz
fix for gcc version 3 bug
Diffstat (limited to 'ndb')
-rw-r--r--ndb/src/common/portlib/gcc.cpp2
-rw-r--r--ndb/src/common/util/new.cpp4
2 files changed, 5 insertions, 1 deletions
diff --git a/ndb/src/common/portlib/gcc.cpp b/ndb/src/common/portlib/gcc.cpp
index 41b1373ee78..66aa4812dc6 100644
--- a/ndb/src/common/portlib/gcc.cpp
+++ b/ndb/src/common/portlib/gcc.cpp
@@ -2,6 +2,6 @@
/**
* GCC linking problem...
*/
-#if ( __GNUC__ == 3 )
+#ifdef DEFINE_CXA_PURE_VIRTUAL
extern "C" { int __cxa_pure_virtual() { return 0;} }
#endif
diff --git a/ndb/src/common/util/new.cpp b/ndb/src/common/util/new.cpp
index 889e83edf6f..b61541b7474 100644
--- a/ndb/src/common/util/new.cpp
+++ b/ndb/src/common/util/new.cpp
@@ -5,6 +5,8 @@ extern "C" {
void (* ndb_new_handler)() = 0;
}
+#ifdef USE_MYSYS_NEW
+
void *operator new (size_t sz)
{
void * p = malloc (sz ? sz : 1);
@@ -36,3 +38,5 @@ void operator delete[] (void *ptr) throw ()
if (ptr)
free(ptr);
}
+
+#endif // USE_MYSYS_NEW