diff options
| author | agc <agc@NetBSD.org> | 2000-02-01 10:46:55 +0000 |
|---|---|---|
| committer | agc <agc@NetBSD.org> | 2000-02-01 10:46:55 +0000 |
| commit | cf6ad330889e4d4f363fffbd3401efd8a0ee7df4 (patch) | |
| tree | ff14636998faa8a0ef027eb6b572493fcecbbb95 /usr.sbin/pkg_install/lib | |
| parent | 0e45514ac98d9b44da342461e222ae264ce33f36 (diff) | |
Set the environment variables to have zero-length strings on Solaris.
Diffstat (limited to 'usr.sbin/pkg_install/lib')
| -rw-r--r-- | usr.sbin/pkg_install/lib/ftpio.c | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/usr.sbin/pkg_install/lib/ftpio.c b/usr.sbin/pkg_install/lib/ftpio.c index a751c3cb65e..ed49861988f 100644 --- a/usr.sbin/pkg_install/lib/ftpio.c +++ b/usr.sbin/pkg_install/lib/ftpio.c @@ -1,4 +1,4 @@ -/* $NetBSD: ftpio.c,v 1.11 2000/01/31 13:39:08 agc Exp $ */ +/* $NetBSD: ftpio.c,v 1.12 2000/02/01 10:46:55 agc Exp $ */ /* Id: foo2.c,v 1.12 1999/12/17 02:31:57 feyrer Exp feyrer */ /* @@ -283,6 +283,9 @@ sigpipe_handler(int n) void ftp_stop(void) { +#if defined(__svr4__) && defined(__sun__) + char env[BUFSIZ]; +#endif char *tmp1, *tmp2; if (!ftp_started) @@ -300,7 +303,12 @@ ftp_stop(void) (void) close(ftpio.answer); } -#if !(defined(__svr4__) && defined(__sun__)) +#if defined(__svr4__) && defined(__sun__) + (void) snprintf(env, sizeof(env), "%s=", PKG_FTPIO_COMMAND); + putenv(env); + (void) snprintf(env, sizeof(env), "%s=", PKG_FTPIO_ANSWER); + putenv(env); +#else unsetenv(PKG_FTPIO_COMMAND); unsetenv(PKG_FTPIO_ANSWER); #endif |
