2
0
mirror of https://github.com/FWGS/xash3d-fwgs synced 2024-11-22 09:56:22 +01:00

Fix 2 instances of void* pointer arithmetic

Partially reverts 341e440c07

Let's see if this fixes the windows build on travis
This commit is contained in:
Gleb Mazovetskiy 2020-12-28 01:20:36 +00:00 committed by Alibek Omarov
parent 7b127c23f5
commit 36b32cad0f
2 changed files with 2 additions and 2 deletions

View File

@ -17,7 +17,7 @@ GNU General Public License for more details.
#include "mod_local.h"
#define list_entry( ptr, type, member ) \
((type *)((void *)(ptr) - (size_t)(&((type *)0)->member)))
((type *)((char *)(ptr) - (size_t)(&((type *)0)->member)))
// iterate over each entry in the list
#define list_for_each_entry( pos, head, member ) \

View File

@ -87,7 +87,7 @@ static const dframetype_t *R_SpriteLoadFrame( model_t *mod, const void *pin, msp
pspriteframe->gl_texturenum = gl_texturenum;
*ppframe = pspriteframe;
return ( const dframetype_t* )(( const void* )pin + sizeof( dspriteframe_t ) + pinframe.width * pinframe.height * bytes );
return ( const dframetype_t* )(( const byte* )pin + sizeof( dspriteframe_t ) + pinframe.width * pinframe.height * bytes );
}
/*