mirror of
https://github.com/dborth/snes9xgx.git
synced 2024-12-28 12:11:51 +01:00
Snes9x - Silence NULL pointer subtraction warning. (#1056)
Use a pointer to address 1 instead.
This commit is contained in:
parent
c0103d65de
commit
6844bb0dd0
@ -48,7 +48,7 @@ enum
|
||||
};
|
||||
|
||||
#define COUNT(ARRAY) (sizeof(ARRAY) / sizeof(ARRAY[0]))
|
||||
#define Offset(field, structure) ((int) (((char *) (&(((structure) NULL)->field))) - ((char *) NULL)))
|
||||
#define Offset(field, structure) ((int) (((char *) (&(((structure) 1)->field))) - ((char *) 1)))
|
||||
#define OFFSET(f) Offset(f, STRUCT *)
|
||||
#define DUMMY(f) Offset(f, struct Obsolete *)
|
||||
#define DELETED(f) (-1)
|
||||
|
Loading…
Reference in New Issue
Block a user