[DragonFlyBSD - Bug #3298] Running "w" and having logged in via XDM through VNC, "w" prints an extra error message

sigttou bugtracker-admin at leaf.dragonflybsd.org
Sun Sep 27 10:53:32 PDT 2026


Issue #3298 has been updated by sigttou.

File w-ttystat-silent-master.patch added

ttystat() called warn() when stat("/dev/<line>") failed.  X11 sessions
(XDM, VNC) have ut_line like ":16", so w(1) printed
"w: /dev/:16: No such file or directory" even though the session is
valid and is still listed.

Fix: only accept the line if the device exists and is a character
device, and return NULL without warning otherwise.  Matches FreeBSD.

----------------------------------------
Bug #3298: Running "w" and having logged in via XDM through VNC, "w" prints an extra error message
http://bugs.dragonflybsd.org/issues/3298#change-14711

* Author: piecuch
* Status: New
* Priority: Normal
* Target version: 6.4
* Start date: 2021-10-25
----------------------------------------
16:10         solitario | root at dragonflybsd /home/adrian # w
16:10         solitario | w: /dev/:16: No such file or directory 6:09PM  up 42954 days,  9:35, 2 users, load 
                          averages: 0,00 0,01 0,00
16:10         solitario | USER     TTY   FROM              LOGIN@  IDLE WHAT
16:10         solitario | adrian   :16   :16              Sun07AM     - -
16:11         solitario | The error is this: "w: /dev/:16: No such file or directory". I think it should not appear 
                          in "w"'s output.


---Files--------------------------------
w-ttystat-silent-master.patch (1 KB)


-- 
You have received this notification because you have either subscribed to it, or are involved in it.
To change your notification preferences, please click here: http://bugs.dragonflybsd.org/my/account


More information about the Bugs mailing list