TTimo / GtkRadiant

The open source, cross platform level editor for idtech games
http://icculus.org/gtkradiant/
Other
586 stars 155 forks source link

Q3data: Fix warning incompatible integer to pointer conversion passing #550

Closed Pan7 closed 7 years ago

Pan7 commented 7 years ago

tools/quake3/q3data/md3lib.c:152:25: warning: incompatible integer to pointer conversion passing 'int' to parameter of type 'FILE ' (aka 'struct __sFILE ') [-Wint-conversion] fileSize = filelength( fileno( fp ) ); ^~~~ tools/quake3/q3data/../common/cmdlib.h:79:25: note: passing argument to parameter 'f' here int Q_filelength( FILE f ); ^ tools/quake3/q3data/md3lib.c:153:32: warning: incompatible integer to pointer conversion passing 'int' to parameter of type 'FILE ' (aka 'struct __sFILE ') [-Wint-conversion] _buffer = malloc( filelength( fileno( fp ) ) ); ^~~~ tools/quake3/q3data/../common/cmdlib.h:79:25: note: passing argument to parameter 'f' here int Q_filelength( FILE f ); ^

See https://github.com/TTimo/GtkRadiant/issues/467

TTimo commented 7 years ago

I pushed this instead: https://github.com/TTimo/GtkRadiant/commit/156fc19c137adaba0b04e6b0ececace3b6216d6b