Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

TRAPALRM and vlock problem



I'm having a problem with the TRAPALRM+TMOUT feature of zsh, and I'd greatly
appreciate any help.  My .zshrc contains:

    TMOUT=300

    TRAPALRM () {
        clear
        echo Inactivity timeout on $TTY
        echo
        vlock -c
        echo
        echo Terminal unlocked. [ Press Enter ]
    }

The goal being, of course, to lock unused terminals after five minutes.

The problem is that when called by zsh in this manner, vlock will only
accept one character, making it impossible to unlock the terminal.  I end
up with:

    This TTY is now locked.
    Please enter the password to unlock.
    kway's Password:
    root's Password:
     *** That password is incorrect; please try again. *** 

    This TTY is now locked.
    Please enter the password to unlock.
    kway's Password:
    root's Password:
     *** That password is incorrect; please try again. *** 

despite the fact that if I all vlock -c from the command line, it works as
expected:

    This TTY is now locked.
    Please enter the password to unlock.
    kway's Password:
    [kway@bean kway]% 

Does anybody know why this happens, or how to stop it?  I'd greatly
appreciate any assistance in this matter.

Kevin Way

Attachment: pgpvkGpI7FuE9.pgp
Description: PGP signature



Messages sorted by: Reverse Date, Date, Thread, Author