about summary refs log tree commit diff stats
path: root/src/custommem.c
diff options
context:
space:
mode:
authorrajdakin <rajdakin@gmail.com>2024-01-18 18:57:20 +0100
committerGitHub <noreply@github.com>2024-01-18 18:57:20 +0100
commit3a2073f78586e9456452485d89e0531607e5d2f4 (patch)
tree9ad61114022ef1c85a5fb50c3a02f863697a6a32 /src/custommem.c
parente963d99d5ee85342e320efe1be8fcde39d3f1a32 (diff)
downloadbox64-3a2073f78586e9456452485d89e0531607e5d2f4.tar.gz
box64-3a2073f78586e9456452485d89e0531607e5d2f4.zip
Fixes (#1207)
* Fixed signed/unsigned issues and other cosmetics

* [WRAPPERS] Fixed missing `return`s in `my_` functions

* [EMU] More fixes

* [STEAM] Forgot one cleanup

* [WRAPPER] Fixed wrappedpulse callback signatures
Diffstat (limited to 'src/custommem.c')
-rw-r--r--src/custommem.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/custommem.c b/src/custommem.c
index 0da20c13..a87ac1e9 100644
--- a/src/custommem.c
+++ b/src/custommem.c
@@ -150,7 +150,7 @@ static size_t getMaxFreeBlock(void* block, size_t block_size, void* start)
     // get start of block
     if(start) {
         blockmark_t *m = (blockmark_t*)start;
-        int maxsize = 0;
+        unsigned int maxsize = 0;
         while(m->next.x32) {    // while there is a subblock
             if(!m->next.fill && m->next.size>maxsize) {
                 maxsize = m->next.size;
@@ -160,7 +160,7 @@ static size_t getMaxFreeBlock(void* block, size_t block_size, void* start)
         return (maxsize>=sizeof(blockmark_t))?maxsize:0;
     } else {
         blockmark_t *m = LAST_BLOCK(block, block_size); // start with the end
-        int maxsize = 0;
+        unsigned int maxsize = 0;
         while(m->prev.x32) {    // while there is a subblock
             if(!m->prev.fill && m->prev.size>maxsize) {
                 maxsize = m->prev.size;
@@ -1505,7 +1505,7 @@ void reserveHighMem()
     if(!p || p[0]=='0')
     #endif
         return; // don't reserve by default
-    intptr_t cur = 1LL<<47;
+    uintptr_t cur = 1ULL<<47;
     mapmem_t* m = mapallmem;
     while(m && (m->end<cur)) {
         m = m->next;