summaryrefslogtreecommitdiff
path: root/build.c
diff options
context:
space:
mode:
authorjbj <devnull@localhost>1998-09-05 18:20:52 +0000
committerjbj <devnull@localhost>1998-09-05 18:20:52 +0000
commitdd8f00921aa4ec5b45d0db8b3b55b8ea109f1fed (patch)
tree974c237149c71e532818658ad3497fdb4c1880a5 /build.c
parent8fa9463826e3aef7ed763b2d1d6bb0937e91b8cd (diff)
downloadlibrpm-tizen-dd8f00921aa4ec5b45d0db8b3b55b8ea109f1fed.tar.gz
librpm-tizen-dd8f00921aa4ec5b45d0db8b3b55b8ea109f1fed.tar.bz2
librpm-tizen-dd8f00921aa4ec5b45d0db8b3b55b8ea109f1fed.zip
Rewrite strsep code using strtok for ANSI C portability.
Remove RPMVAR_SETENV for now. CVS patchset: 2278 CVS date: 1998/09/05 18:20:52
Diffstat (limited to 'build.c')
-rw-r--r--build.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/build.c b/build.c
index 30fc022f4..ec36986a0 100644
--- a/build.c
+++ b/build.c
@@ -144,7 +144,7 @@ int build(char *arg, int buildAmount, char *passPhrase,
char * rcfile, char * arch, char * os,
char *buildplatforms)
{
- char * platform;
+ char *platform, *t;
int rc;
if (buildplatforms == NULL) {
@@ -157,7 +157,9 @@ int build(char *arg, int buildAmount, char *passPhrase,
printf("building these platforms: %s\n", buildplatforms);
- while((platform = strsep(&buildplatforms,",")) != NULL) {
+ t = buildplatforms;
+ while((platform = strtok(t, ",")) != NULL) {
+ t = NULL;
printf("building %s\n", platform);
rpmSetVar(RPMVAR_BUILDPLATFORM,platform);