diff options
author | rsc <devnull@localhost> | 2007-04-21 22:37:13 +0000 |
---|---|---|
committer | rsc <devnull@localhost> | 2007-04-21 22:37:13 +0000 |
commit | d0648192ab892f41213db3a3d92b0619de995e3d (patch) | |
tree | 9e1a391cec70ca58f3dce33cb9c4f1199f6439af /src/cmd/htmlroff | |
parent | 14b4a4702c719bf185dde797999a0ba5cad5465f (diff) | |
download | plan9port-d0648192ab892f41213db3a3d92b0619de995e3d.tar.gz plan9port-d0648192ab892f41213db3a3d92b0619de995e3d.tar.bz2 plan9port-d0648192ab892f41213db3a3d92b0619de995e3d.zip |
warn about \w no arg
Diffstat (limited to 'src/cmd/htmlroff')
-rw-r--r-- | src/cmd/htmlroff/t11.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/cmd/htmlroff/t11.c b/src/cmd/htmlroff/t11.c index 53d68aac..dd1dd75b 100644 --- a/src/cmd/htmlroff/t11.c +++ b/src/cmd/htmlroff/t11.c @@ -72,8 +72,13 @@ e_w(void) { Rune *a; Rune buf[40]; - + static Rune zero; + a = getqarg(); + if(a == nil){ + warn("no arg for \\w"); + a = &zero; + } runesnprint(buf, sizeof buf, "%ld", runestrlen(a)); pushinputstring(buf); nr(L("st"), 0); |