** First allocation will fail whenever not building initial state. ** (This fail will trigger 'tryagain' and a full GC cycle at every ** allocation.) */
| 29 | ** allocation.) |
| 30 | */ |
| 31 | static void *firsttry (global_State *g, void *block, size_t os, size_t ns) { |
| 32 | if (completestate(g) && ns > 0) /* frees never fail */ |
| 33 | return NULL; /* fail */ |
| 34 | else /* normal allocation */ |
| 35 | return (*g->frealloc)(g->ud, block, os, ns); |
| 36 | } |
| 37 | #else |
| 38 | #define firsttry(g,block,os,ns) ((*g->frealloc)(g->ud, block, os, ns)) |
| 39 | #endif |
no outgoing calls
no test coverage detected