From 362ec6f10ca07023b5af59beee8f9c41ddec9eb1 Mon Sep 17 00:00:00 2001 From: Sam Lantinga Date: Thu, 17 Dec 2009 07:46:13 +0000 Subject: [PATCH] Updated test code to use SDL_setenv() --- src/stdlib/SDL_getenv.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/stdlib/SDL_getenv.c b/src/stdlib/SDL_getenv.c index 02b9348ac..c9f2988b2 100644 --- a/src/stdlib/SDL_getenv.c +++ b/src/stdlib/SDL_getenv.c @@ -214,7 +214,7 @@ main(int argc, char *argv[]) } printf("Setting FIRST=VALUE1 in the environment... "); fflush(stdout); - if (SDL_putenv("FIRST=VALUE1") == 0) { + if (SDL_setenv("FIRST", "VALUE1", 0) == 0) { printf("okay\n"); } else { printf("failed\n"); @@ -229,7 +229,7 @@ main(int argc, char *argv[]) } printf("Setting SECOND=VALUE2 in the environment... "); fflush(stdout); - if (SDL_putenv("SECOND=VALUE2") == 0) { + if (SDL_setenv("SECOND", "VALUE2", 0) == 0) { printf("okay\n"); } else { printf("failed\n"); @@ -244,7 +244,7 @@ main(int argc, char *argv[]) } printf("Setting FIRST=NOVALUE in the environment... "); fflush(stdout); - if (SDL_putenv("FIRST=NOVALUE") == 0) { + if (SDL_setenv("FIRST", "NOVALUE", 1) == 0) { printf("okay\n"); } else { printf("failed\n"); @@ -267,4 +267,5 @@ main(int argc, char *argv[]) return (0); } #endif /* TEST_MAIN */ + /* vi: set ts=4 sw=4 expandtab: */