diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/custommem.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/custommem.c b/src/custommem.c index a88674fd..9f5422a9 100644 --- a/src/custommem.c +++ b/src/custommem.c @@ -433,7 +433,7 @@ mmapchunk_t* addChunk(size_t mmapsize) { mmaplist = (mmaplist_t*)box_calloc(1, sizeof(mmaplist_t)); mmaplist_t* head = mmaplist; size_t i = mmapsize; - while(i) { + while(1) { if(i>=NCHUNK) { i-=NCHUNK; if(!head->next) { @@ -443,7 +443,6 @@ mmapchunk_t* addChunk(size_t mmapsize) { } else return &head->chunks[i]; } - return NULL; // never reached } uintptr_t FindFreeDynarecMap(dynablock_t* db, size_t size) |