We are currently migrating Bugzilla to GitHub issues.
Any changes made to the bug tracker now will be lost, so please do not post new bugs or make changes to them.
When we're done, all bug URLs will redirect to their equivalent location on the new bug tracker.

Bug 2262

Summary: Some public functions aren't marked with SDLCALL
Product: SDL Reporter: Ryan C. Gordon <icculus>
Component: buildAssignee: Ryan C. Gordon <icculus>
Status: RESOLVED FIXED QA Contact: Sam Lantinga <slouken>
Severity: normal    
Priority: P2    
Version: HG 2.0   
Hardware: x86   
OS: Other   

Description Ryan C. Gordon 2013-11-22 21:30:17 UTC
There are 4 functions we forgot to mark as SDLCALL...

[icculus@caridad ~/projects/SDL/include]$ grep "extern DECLSPEC" * |grep -v SDLCALL
SDL_joystick.h:extern DECLSPEC void SDL_JoystickGetGUIDString(SDL_JoystickGUID guid, char *pszGUID, int cbGUID);
SDL_main.h:extern DECLSPEC void SDL_SetMainReady(void);
SDL_render.h:extern DECLSPEC int SDL_SetRenderDrawColor(SDL_Renderer * renderer, Uint8 r, Uint8 g, Uint8 b, Uint8 a);
SDL_render.h:extern DECLSPEC int SDL_GetRenderDrawColor(SDL_Renderer * renderer, Uint8 * r, Uint8 * g, Uint8 * b, Uint8 * a);

I _think_ we can fix these without breaking the ABI, because SDL2's SDLCALL is #defined to nothing on everything except non-GNU Windows compilers, where it's defined to __cdecl...which would also be the default in any modern C compiler...right?!

(If this only breaks old installs of...Watcom C or something, I say let's fix it.)

--ryan.
Comment 1 Sam Lantinga 2013-11-23 04:53:51 UTC
Yep, fixing this doesn't break ABI and should be done.
Comment 2 Ryan C. Gordon 2013-11-23 20:54:28 UTC
Fixed in https://hg.libsdl.org/SDL/rev/e3e00f8e6b91

--ryan.