package xvt
tags 650396 + patch
thanks

I forgot the patch text!


--- xvt-2.1.debian/ttyinit.c    2011-11-29 03:13:19.000000000 +0100
+++ xvt-2.1/ttyinit.c   2011-11-29 03:51:29.000000000 +0100
@@ -235,10 +235,12 @@ write_utmp()
        struct passwd *pw;
 
 #ifdef SVR4_UTMP
+       setutent();
        memset(&utent,0,sizeof(utent));
        utent.ut_type = USER_PROCESS;
        strncpy(utent.ut_id,tty_name + 8,sizeof(utent.ut_id));
        strncpy(utent.ut_line,tty_name + 5,sizeof(utent.ut_line));
+       utent.ut_pid = comm_pid;
        pw = getpwuid(getuid());
        if (pw != NULL)
                strncpy(utent.ut_name,pw->pw_name,sizeof(utent.ut_name));
@@ -246,6 +248,7 @@ write_utmp()
        time(&utent.ut_time);
        pututline(&utent);
        endutent();
+       updwtmp(WTMP_FILE, &utent);
 #endif /* SVR4_UTMP */
 
 #ifdef SVR4_UTMPX
@@ -338,6 +341,7 @@ tidy_utmp()
        utent.ut_type = DEAD_PROCESS;
        time(&utent.ut_time);
        pututline(&utent);
+       logwtmp(utent.ut_line, "", "");
 #endif /* SVR4_UTMP || SVR4_UTMPX */
 #ifdef SVR4_UTMPX
        updwtmp(WTMP_FILE,&utent);



-- 
To UNSUBSCRIBE, email to [email protected]
with a subject of "unsubscribe". Trouble? Contact [email protected]

Reply via email to