diff --git a/src/blua/liolib.c b/src/blua/liolib.c index 2d20f5292aea485878b4b8903d4902cd3240982a..e3d8a24874571df40507665ae7369e06598507c0 100644 --- a/src/blua/liolib.c +++ b/src/blua/liolib.c @@ -166,8 +166,10 @@ static int StartsWith(const char *a, const char *b) // this is wolfs being lazy static int io_open (lua_State *L) { - const char *filename = luaL_checkstring(L, 1); - int pass = 0; int i; + const char *Cfilename = luaL_checkstring(L, 1); + char *filename = strdup(Cfilename); + int pass = 0; + size_t i; int length = strlen(filename) - 1; for (i = 0; i < (sizeof (whitelist) / sizeof(const char *)); i++) { diff --git a/src/d_clisrv.c b/src/d_clisrv.c index 2fb021017ae724b2b1152f7f86a67b6b40f367a3..cc1b3305e851e806c0d3712a68ba832dd07574b9 100644 --- a/src/d_clisrv.c +++ b/src/d_clisrv.c @@ -2294,11 +2294,13 @@ static void Command_connect(void) } } - if (gametype == INT32_MAX) +#if 0 // gametype will never equal INT32_MAX + if (gametype == INT32_MAX) { CONS_Alert(CONS_ERROR, M_GetText("Invalid gametype %s\n"), COM_Argv(3)); return; } +#endif // Goodbye, we're off to host a server CV_SetValue(&cv_nextmap, newmapnum); diff --git a/src/p_mobj.h b/src/p_mobj.h index c31732b6dc13db6e00813d4de1d3e467a1018b68..3a00e00435cd933e37bd02bb541c86d030c81777 100644 --- a/src/p_mobj.h +++ b/src/p_mobj.h @@ -457,5 +457,5 @@ extern INT32 numstarposts; boolean camera_motionblur; INT32 forward_postimgparam; -boolean P_CheckMotionBlur(); +boolean P_CheckMotionBlur(void); void P_SetActiveMotionBlur(boolean active, INT32 param); diff --git a/src/sdl/i_system.c b/src/sdl/i_system.c index 1f614d8c085ba04943a2b42851a43455cabc3107..71ee3f79474b6bb48b23a2fbf4127a74fd40e115 100644 --- a/src/sdl/i_system.c +++ b/src/sdl/i_system.c @@ -23,7 +23,7 @@ #ifdef CMAKECONFIG #include "config.h" #else -#include "config.h.in" +#include "../config.h.in" #endif #ifndef _WIN32_WCE diff --git a/src/sdl/mixer_sound.c b/src/sdl/mixer_sound.c index c824ad9832106cc70ad94c7007ed30bccac7e8e4..c45d2b5833682e0ca1fd48e747c9cbaa60a5c114 100644 --- a/src/sdl/mixer_sound.c +++ b/src/sdl/mixer_sound.c @@ -472,6 +472,8 @@ static void mixmusic_callback(void *udata, Uint8 *stream, int len) music_pos += len/4; music_pos_time = SDL_GetTicks(); } + (void)udata; + (void)stream; //I_OutputMsg("MusicPos: %.3f", music_pos); //HU_DoCEcho(va("MusicPos: %.3f\\Stream: %d\\Length: %i", music_pos,stream,len)); } diff --git a/src/sounds.c b/src/sounds.c index ecfc75771e87e83723e05bfc99de3bb86147c676..f85a70a7de671e13e157dc02cd74451f215eb61a 100644 --- a/src/sounds.c +++ b/src/sounds.c @@ -478,7 +478,6 @@ void S_InitRuntimeSounds (void) sfxenum_t i; INT32 value; char soundname[7]; - char musicname[7]; for (i = sfx_freeslot0; i <= sfx_lastskinsoundslot; i++) { diff --git a/src/v_video.c b/src/v_video.c index 390f212ea8d5406a8330aeae0ee12a610bce9cf1..0414f9a1b00e5025e1e05d0dd70f1adac1805a21 100644 --- a/src/v_video.c +++ b/src/v_video.c @@ -2037,8 +2037,8 @@ Unoptimized version float cosma = cos(f_angle); - float xst = (INT32)round((cosma * -hwidth - sinma * -hheight) + hwidth); - float yst = (INT32)round((sinma * -hwidth + cosma * -hheight) + hheight); + float xst = round((cosma * -hwidth - sinma * -hheight) + hwidth); + float yst = round((sinma * -hwidth + cosma * -hheight) + hheight); // Fills the empty space with a solid color from palette index memset(screens[4], (UINT8)(31), vid.width*vid.height*vid.bpp);