Only in inetutils-1.4.2: build.sh Only in inetutils-1.4.2: extra-includes Only in inetutils-1.4.2: inetutils-1.4.2-tivo-s1-3.patch diff -ur inetutils-1.4.2-orig/rcp/rcp.c inetutils-1.4.2/rcp/rcp.c --- inetutils-1.4.2-orig/rcp/rcp.c 2002-09-02 15:14:39.000000000 +0100 +++ inetutils-1.4.2/rcp/rcp.c 2005-01-22 23:07:26.000000000 +0000 @@ -498,7 +498,7 @@ #endif snprintf (buf, sizeof(buf), "T%ld %ld %ld %ld\n", - a_sec, a_usec, m_sec, m_usec); + m_sec, m_usec, a_sec, a_usec); return write (fd, buf, strlen (buf)); } diff -ur inetutils-1.4.2-orig/rlogind/rlogind.c inetutils-1.4.2/rlogind/rlogind.c --- inetutils-1.4.2-orig/rlogind/rlogind.c 2002-06-26 04:15:06.000000000 +0100 +++ inetutils-1.4.2/rlogind/rlogind.c 2005-03-20 17:58:53.000000000 +0000 @@ -91,10 +91,10 @@ #ifndef TTYDEF_IFLAG #define TTYDEF_IFLAG (BRKINT | ISTRIP | ICRNL | IMAXBEL | IXON | IXANY) #endif -#ifndef TTYDEF_OFLAG #ifndef OXTABS #define OXTABS 0 #endif +#ifndef TTYDEF_OFLAG #define TTYDEF_OFLAG (OPOST | ONLCR | OXTABS) #endif #ifndef TTYDEF_LFLAG @@ -598,8 +598,12 @@ tt.c_oflag = TTYDEF_OFLAG; tt.c_lflag = TTYDEF_LFLAG; tcsetattr (fd, TCSAFLUSH, &tt); +#ifdef PRESERVE_ENVIRONMENT + setenv ("TERM", ap->term+ENVSIZE, 1); +#else ap->env[0] = ap->term; ap->env[1] = 0; +#endif } #ifdef UTMPX @@ -621,10 +625,14 @@ { if (authenticated) { -#ifdef SOLARIS +#if defined(SOLARIS) execle (path_login, "login", "-p", "-h", ap->hostname, ap->term, "-f", "--", ap->lusername, NULL, ap->env); +#elif PRESERVE_ENVIRONMENT + execl (path_login, "login", "-p", + "-h", ap->hostname, "-f", + ap->lusername, NULL); #else execle (path_login, "login", "-p", "-h", ap->hostname, "-f", @@ -633,10 +641,14 @@ } else { -#ifdef SOLARIS +#if defined(SOLARIS) execle (path_login, "login", "-p", "-h", ap->hostname, ap->term, "--", ap->lusername, NULL, ap->env); +#elif PRESERVE_ENVIRONMENT + execl (path_login, "login", "-p", + "-h", ap->hostname, + ap->lusername, NULL); #else execle (path_login, "login", "-p", "-h", ap->hostname, diff -ur inetutils-1.4.2-orig/rsh/rsh.c inetutils-1.4.2/rsh/rsh.c --- inetutils-1.4.2-orig/rsh/rsh.c 2002-06-26 04:15:06.000000000 +0100 +++ inetutils-1.4.2/rsh/rsh.c 2005-01-23 00:25:33.000000000 +0000 @@ -97,12 +97,12 @@ #ifdef KERBEROS #ifdef ENCRYPTION -#define OPTIONS "8Kdek:l:nxVh" +#define OPTIONS "+8Kdek:l:nxVh" #else -#define OPTIONS "8Kdek:l:nVh" +#define OPTIONS "+8Kdek:l:nVh" #endif #else -#define OPTIONS "8KLdel:nVh" +#define OPTIONS "+8KLdel:nVh" #endif static const char *short_options = OPTIONS; static struct option long_options[] = diff -ur inetutils-1.4.2-orig/rshd/rshd.c inetutils-1.4.2/rshd/rshd.c --- inetutils-1.4.2-orig/rshd/rshd.c 2002-12-11 12:38:00.000000000 +0000 +++ inetutils-1.4.2/rshd/rshd.c 2005-01-29 00:16:34.000000000 +0000 @@ -461,14 +461,14 @@ #ifdef KERBEROS if (!use_kerberos) #endif - if (check_all || local_domain (hp->h_name)) - { - char *remotehost = (char *) alloca (strlen (hp->h_name) + 1); - if (! remotehost) - errorstr = "Out of memory\n"; - else - { - strcpy (remotehost, hp->h_name); + { + char *remotehost = (char *) alloca (strlen (hp->h_name) + 1); + if (! remotehost) + errorstr = "Out of memory\n"; + else + { + strcpy (remotehost, hp->h_name); + if (check_all || local_domain (remotehost)) { errorhost = remotehost; hp = gethostbyname (remotehost); if (hp == NULL) @@ -500,6 +500,7 @@ } } } + } } else errorhost = hostname = inet_ntoa (fromp->sin_addr); diff -ur inetutils-1.4.2-orig/telnetd/pty.c inetutils-1.4.2/telnetd/pty.c --- inetutils-1.4.2-orig/telnetd/pty.c 2002-04-07 12:55:40.000000000 +0100 +++ inetutils-1.4.2/telnetd/pty.c 2005-03-20 18:11:40.000000000 +0000 @@ -80,6 +80,7 @@ return master; } +#if !PRESERVE_ENVIRONMENT extern char **environ; /* * scrub_env() @@ -104,6 +105,7 @@ } *cpp2 = 0; } +#endif void start_login (char *host, int autologin, char *name) @@ -112,7 +114,9 @@ int argc; char **argv; +#if !PRESERVE_ENVIRONMENT scrub_env (); +#endif /* Set the environment variable "LINEMODE" to indicate our linemode */ if (lmodetype == REAL_LINEMODE) diff -ur inetutils-1.4.2-orig/telnetd/telnetd.c inetutils-1.4.2/telnetd/telnetd.c --- inetutils-1.4.2-orig/telnetd/telnetd.c 2002-06-26 04:15:07.000000000 +0100 +++ inetutils-1.4.2/telnetd/telnetd.c 2005-01-28 20:05:47.000000000 +0000 @@ -57,9 +57,9 @@ char *login_invocation = #ifdef SOLARIS -"/bin/login -h %h %?T{TERM=%T}{-} %?u{%?a{-f }-- %u}" +PATH_LOGIN " -h %h %?T{TERM=%T}{-} %?u{%?a{-f }-- %u}" #else -"/bin/login -p -h %h %?u{-f %u}" +PATH_LOGIN " -p -h %h %?u{-f %u}" #endif ; @@ -654,7 +654,7 @@ Options are:\n\ -a, --authmode AUTHMODE specify what mode to use for authentication\n\ -D, --debug[=LEVEL] set debugging level\n\ - -E, --exec-login STRING set program to be executed instead of /bin/login\n\ + -E, --exec-login STRING set program to be executed instead of " PATH_LOGIN "\n\ -h, --no-hostinfo do not print host information before login has\n\ been completed\n\ -l, --linemode[=MODE] set line mode\n\ diff -ur inetutils-1.4.2-orig/telnetd/telnetd.h inetutils-1.4.2/telnetd/telnetd.h --- inetutils-1.4.2-orig/telnetd/telnetd.h 2002-04-12 22:33:42.000000000 +0100 +++ inetutils-1.4.2/telnetd/telnetd.h 2005-01-28 21:29:49.000000000 +0000 @@ -130,7 +130,7 @@ #ifdef HAVE_UNAME /* Prefix and suffix if the IM string can be generated from uname. */ # define UNAME_IM_PREFIX "\r\n" -# define UNAME_IM_SUFFIX " (%h) (%t)\r\n\n" +# define UNAME_IM_SUFFIX " (%l) (%t)\r\n\n" #else /* ! HAVE_UNAME */ # define UNAME_IM_PREFIX "\r\n" # define UNAME_IM_SUFFIX "\r\n" @@ -375,6 +375,8 @@ extern void willoption P((int)); extern void wontoption P((int)); +extern char* localhost P((void)); + #ifdef ENCRYPTION extern void (*encrypt_output) P((unsigned char *, int)); extern int (*decrypt_input) P((int));