diff options
Diffstat (limited to 'src/corelib/tools/qlist.cpp')
-rw-r--r-- | src/corelib/tools/qlist.cpp | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/src/corelib/tools/qlist.cpp b/src/corelib/tools/qlist.cpp index 9ac46365a2..adc6ee7a4b 100644 --- a/src/corelib/tools/qlist.cpp +++ b/src/corelib/tools/qlist.cpp @@ -42,7 +42,9 @@ #include <new> #include "qlist.h" #include "qtools_p.h" + #include <string.h> +#include <stdlib.h> QT_BEGIN_NAMESPACE @@ -82,7 +84,7 @@ QListData::Data *QListData::detach_grow(int *idx, int num) int l = x->end - x->begin; int nl = l + num; int alloc = grow(nl); - Data* t = static_cast<Data *>(qMalloc(DataHeaderSize + alloc * sizeof(void *))); + Data* t = static_cast<Data *>(::malloc(DataHeaderSize + alloc * sizeof(void *))); Q_CHECK_PTR(t); t->ref = 1; @@ -124,7 +126,7 @@ QListData::Data *QListData::detach_grow(int *idx, int num) QListData::Data *QListData::detach(int alloc) { Data *x = d; - Data* t = static_cast<Data *>(qMalloc(DataHeaderSize + alloc * sizeof(void *))); + Data* t = static_cast<Data *>(::malloc(DataHeaderSize + alloc * sizeof(void *))); Q_CHECK_PTR(t); t->ref = 1; @@ -145,7 +147,7 @@ QListData::Data *QListData::detach(int alloc) void QListData::realloc(int alloc) { Q_ASSERT(d->ref == 1); - Data *x = static_cast<Data *>(qRealloc(d, DataHeaderSize + alloc * sizeof(void *))); + Data *x = static_cast<Data *>(::realloc(d, DataHeaderSize + alloc * sizeof(void *))); Q_CHECK_PTR(x); d = x; |