Port to new spec M_MEMORY_FULL
This commit is contained in:
1 parent
450d2c9000
commit
1e196fe22a
21 files changed
+88
-87
No files matched your search
@@ -181,7 +181,7 @@
|
||||
size_t def = d->default_size; \
|
||||
/* Test for overflow of the size computation */ \
|
||||
if (M_UNLIKELY_NOMEM (def > SIZE_MAX / sizeof (type) - sizeof(node_t))) { \
|
||||
M_MEMORY_FULL(sizeof(node_t)+def * sizeof(type)); \
|
||||
M_MEMORY_FULL(char, sizeof(node_t)+def * sizeof(type)); \
|
||||
abort(); \
|
||||
return NULL; \
|
||||
} \
|
||||
@@ -190,7 +190,7 @@
|
||||
M_CALL_REALLOC(oplist, char, NULL, 0, \
|
||||
sizeof(node_t) + def * sizeof(type) ); \
|
||||
if (M_UNLIKELY_NOMEM (n==NULL)) { \
|
||||
M_MEMORY_FULL(sizeof(node_t)+def * sizeof(type)); \
|
||||
M_MEMORY_FULL(char, sizeof(node_t)+def * sizeof(type)); \
|
||||
abort(); \
|
||||
return NULL; \
|
||||
} \
|
||||
|
||||
Reference in new issue
Block a user