include/SDL_stdinc.h
changeset 3581 15eea7a1fa97
parent 3567 fb9ea4b549c3
child 3697 f7b03b6838cb
     1.1 --- a/include/SDL_stdinc.h	Wed Dec 16 08:17:05 2009 +0000
     1.2 +++ b/include/SDL_stdinc.h	Wed Dec 16 10:59:51 2009 +0000
     1.3 @@ -267,20 +267,12 @@
     1.4  extern DECLSPEC char *SDLCALL SDL_getenv(const char *name);
     1.5  #endif
     1.6  
     1.7 -/**
     1.8 - * \warning On some platforms, the string you pass to SDL_putenv() becomes
     1.9 - *          part of the environment table directly...it will use this specific
    1.10 - *          buffer, and not a copy of it! This means you can't free it, and
    1.11 - *          other pieces of code may try to write to it. In practice, this
    1.12 - *          isn't a big deal, but be aware of the possibility.
    1.13 - *          However, due to this issue, you should be prepared to
    1.14 - *          pass a (char*), or be willing to cast away the constness of your
    1.15 - *          string for this call.
    1.16 - */
    1.17 -#ifdef HAVE_PUTENV
    1.18 -#define SDL_putenv	putenv
    1.19 +/* SDL_putenv() has moved to SDL_compat. */
    1.20 +#ifdef HAVE_SETENV
    1.21 +#define SDL_setenv	setenv
    1.22  #else
    1.23 -extern DECLSPEC int SDLCALL SDL_putenv(const char *variable);
    1.24 +extern DECLSPEC int SDLCALL SDL_setenv(const char *name, const char *value,
    1.25 +                                       int overwrite);
    1.26  #endif
    1.27  
    1.28  #ifdef HAVE_QSORT