chris@hwcs.UUCP (Chris Miller) (11/01/84)
Description: We have encountered problems with "ed" failing (message is '?TMP'), presumably because the file /tmp/whatis is too large. This results in the whole of /usr/lib/whatis being corrupted whenever "catman" is run. Repeat-By: Expand your manual with enough new sections (number unknown!) and type "/etc/catman -w" as a sufficiently privileged user. Fix: Replace the use of "ed" in /usr/src/usr.lib/makewhatis.sh (on 4.2bsd, wherever appropriate on earlier releases) by "sed". (This also runs noticeably faster). We have also added commands to remove nroff font- and size-change commands embedded in header lines. Diff listing follows: 9,17c9,16 < ed - /tmp/whatis <<\! < g/\\-/s//-/ < g/\\\*-/s//-/ < g/ VAX-11/s/// < 1,$s/.TH [^ ]* \([^ ]*\).* \([^-]*\)/\2(\1) / < g/ /s// /g < w /tmp/whatis2 < q < ! --- > sed </tmp/whatis >/tmp/whatis2 \ > -e 's/\\-/-/' \ > -e 's/\\\*-/-/' \ > -e 's/ VAX-11//' \ > -e 's/\\f[PRIB0123]//g' \ > -e 's/\\s[-+0-9]*//g' \ > -e 's/.TH [^ ]* \([^ ]*\).* \([^-]*\)/\2(\1) /' \ > -e 's/ / /g' -- Chris Miller Department of Computer Science Heriot-Watt University ...!ukc!{edcaad,west44}!hwcs