From 2e498f754e694bb67cf2fb2a2037dc2997e33ea7 Mon Sep 17 00:00:00 2001 From: ache Date: Mon, 30 Apr 2007 04:29:17 +0000 Subject: Eliminate error with -W* strict flags and make putenv() calls conforming to standard in the same way as f.e. gcc internal portable code does. --- bin/df/df.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'bin/df') diff --git a/bin/df/df.c b/bin/df/df.c index 5420da9..0350d98 100644 --- a/bin/df/df.c +++ b/bin/df/df.c @@ -131,14 +131,14 @@ main(int argc, char *argv[]) */ if (kflag) break; - putenv("BLOCKSIZE=512"); + putenv(strdup("BLOCKSIZE=512")); hflag = 0; break; case 'c': cflag = 1; break; case 'g': - putenv("BLOCKSIZE=1g"); + putenv(strdup("BLOCKSIZE=1g")); hflag = 0; break; case 'H': @@ -152,7 +152,7 @@ main(int argc, char *argv[]) break; case 'k': kflag++; - putenv("BLOCKSIZE=1024"); + putenv(strdup("BLOCKSIZE=1024")); hflag = 0; break; case 'l': @@ -162,7 +162,7 @@ main(int argc, char *argv[]) lflag = 1; break; case 'm': - putenv("BLOCKSIZE=1m"); + putenv(strdup("BLOCKSIZE=1m")); hflag = 0; break; case 'n': -- cgit v1.1