DragonFly bugs List (threaded) for 2009-04
[
Date Prev][
Date Next]
[Thread Prev][
Thread Next]
[
Date Index][
Thread Index]
[issue1337] HEAD can't build 2.2-RELEASE
Thomas Nikolajsen <thomas.nikolajsen@mail.dk> added the comment:
On HEAD building 2.0-RELEASE with your patch applied doesn't fail.
I will commit patch in case to 2.2-RELEASE & 2.0-RELEASE in one week
if no one objects.
-thomas
_____________________________________________________
DragonFly issue tracker <bugs@lists.dragonflybsd.org>
<http://bugs.dragonflybsd.org/issue1337>
_____________________________________________________
diff --git a/usr.bin/env/env.c b/usr.bin/env/env.c
index 468649b..8b59033 100644
--- a/usr.bin/env/env.c
+++ b/usr.bin/env/env.c
@@ -65,8 +65,10 @@ main(int argc, char **argv)
usage();
}
for (argv += optind; *argv && (p = strchr(*argv, '=')); ++argv) {
- if (setenv(*argv, ++p, 1) == -1)
- err(1, "setenv: cannot set %s=%s", *argv, p);
+ *p = '\0';
+ if (setenv(*argv, p + 1, 1) == -1)
+ err(1, "setenv: cannot set %s=%s", *argv, p + 1);
+ *p = '=';
}
if (*argv) {
[
Date Prev][
Date Next]
[Thread Prev][
Thread Next]
[
Date Index][
Thread Index]