--- rxvt-unicode/src/logging.C 2006/01/17 15:17:39 1.31 +++ rxvt-unicode/src/logging.C 2006/01/18 16:34:53 1.34 @@ -168,7 +168,7 @@ { # ifdef HAVE_TTYSLOT int fdstdin = dup (STDIN_FILENO); - dup2 (pty->tty, STDIN_FILENO); + dup2 (tty, STDIN_FILENO); i = ttyslot (); if (rxvt_write_bsd_utmp (i, ut)) @@ -205,9 +205,9 @@ #endif #ifdef WTMP_SUPPORT -# ifdef WTMP_ONLY_ON_LOGIN +#ifdef LOG_ONLY_ON_LOGIN if (login_shell) -# endif +#endif { # ifdef HAVE_STRUCT_UTMP # ifdef HAVE_UPDWTMP @@ -222,7 +222,9 @@ } #endif #if defined(LASTLOG_SUPPORT) && defined(RXVT_LASTLOG_FILE) +#ifdef LOG_ONLY_ON_LOGIN if (login_shell) +#endif rxvt_update_lastlog (RXVT_LASTLOG_FILE, pty, hostname); #endif } @@ -281,9 +283,9 @@ * Write ending wtmp entry */ #ifdef WTMP_SUPPORT -# ifdef WTMP_ONLY_ON_LOGIN +#ifdef LOG_ONLY_ON_LOGIN if (login_shell) -# endif +#endif { # ifdef HAVE_STRUCT_UTMP # ifdef HAVE_UPDWTMP