[MPlayer-cvslog] r31902 - trunk/loader/win32.c
reimar
subversion at mplayerhq.hu
Mon Aug 2 19:30:00 CEST 2010
Author: reimar
Date: Mon Aug 2 19:30:00 2010
New Revision: 31902
Log:
Avoid arithmetic on void * pointers.
Modified:
trunk/loader/win32.c
Modified: trunk/loader/win32.c
==============================================================================
--- trunk/loader/win32.c Mon Aug 2 19:27:20 2010 (r31901)
+++ trunk/loader/win32.c Mon Aug 2 19:30:00 2010 (r31902)
@@ -4748,7 +4748,7 @@ static void WINAPI expGlobalMemoryStatus
lpmem->dwAvailPageFile = 16*1024*1024;
}
expGetSystemInfo(&si);
- lpmem->dwTotalVirtual = si.lpMaximumApplicationAddress-si.lpMinimumApplicationAddress;
+ lpmem->dwTotalVirtual = (uint8_t *)si.lpMaximumApplicationAddress-(uint8_t *)si.lpMinimumApplicationAddress;
/* FIXME: we should track down all the already allocated VM pages and substract them, for now arbitrarily remove 64KB so that it matches NT */
lpmem->dwAvailVirtual = lpmem->dwTotalVirtual-64*1024;
memcpy(&cached_memstatus,lpmem,sizeof(MEMORYSTATUS));
More information about the MPlayer-cvslog
mailing list