summaryrefslogtreecommitdiff
path: root/src/stdlib
diff options
context:
space:
mode:
authorSam Lantinga <slouken@libsdl.org>2009-12-17 07:46:13 +0000
committerSam Lantinga <slouken@libsdl.org>2009-12-17 07:46:13 +0000
commit0833d1cda21c7b44e7ae478b25f88b89c09ded79 (patch)
tree7d418ce0d35b10435b7d9f592cf681eb772a0948 /src/stdlib
parenta9012609d37db78d9e3a3dbcdf0fb91464a1beba (diff)
Updated test code to use SDL_setenv()
--HG-- extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/trunk%404340
Diffstat (limited to 'src/stdlib')
-rw-r--r--src/stdlib/SDL_getenv.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/stdlib/SDL_getenv.c b/src/stdlib/SDL_getenv.c
index 02b9348a..c9f2988b 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: */