summary |
tags |
clone url |
shortlog |
log |
commit | commitdiff |
tree
raw |
patch |
inline | side by side (from parent 1:
0db0015)
SCCS-vsn: usr.bin/w/w.c 5.30
#endif /* not lint */
#ifndef lint
#endif /* not lint */
#ifndef lint
-static char sccsid[] = "@(#)w.c 5.29 (Berkeley) %G%";
+static char sccsid[] = "@(#)w.c 5.30 (Berkeley) %G%";
if (argwidth < 4)
argwidth = 8;
for (ep = ehead; ep != NULL; ep = ep->next) {
if (argwidth < 4)
argwidth = 8;
for (ep = ehead; ep != NULL; ep = ep->next) {
+ if (ep->proc == 0) {
+ ep->args = "-";
+ continue;
+ }
ep->args = strdup(kvm_getargs(ep->proc, kvm_getu(ep->proc)));
if (ep->args == NULL) {
error("out of memory");
ep->args = strdup(kvm_getargs(ep->proc, kvm_getu(ep->proc)));
if (ep->args == NULL) {
error("out of memory");