- warn about messages with an unexpected quote character
- warn about extra characters after a quote character
- warn about an unterminated quoted message
- Store an empty string in the catalog when the message text is empty an
a <blank> (space or tab) field separator is present.
Standards: The Open Group Base Specifications Issue 6
IEEE Std 1003.1, 2004 Edition
- Accept "-" for msgfile (STDIN) and catfile (STDOUT)
- Merge msgfile into formatted catfile. The catfile is created if
it does not exist (current behavior). If the catfile exists,
its messages are included in the new catfile. Collisions between
set and message numbers cause the msgfile message text to replace
the existing message text.
(The $delset directive now makes more sense.)
Standards: The Open Group Base Specifications Issue 6
IEEE Std 1003.1, 2004 Edition
- Replace corrupt()/nomem() with errx(). The replaced routines
called local error() -> warning() which prints an input file line
number. This probably makes no sense for these conditions (it
is not a syntax error in msgfile). Line numbers are completely
nonsense when dealing with reading a formatted catfile.
- Modify warning() to only print line number when reading from a
message file. Also print the current file being processed.
- Don't issue a warning when processing a line with only a message
number and no trailing space. This is valid and will delete any
existing message with that number from the current set.
- Reset lineno for each msgfile processed.
- "If no $set directive is specified in a message text source file,
all messages shall be located in an implementation-defined default
message set NL_SETD."
- The n argument to $delset indicates the set number which should be
in the range 1 to NL_SETMAX.
Standards: The Open Group Base Specifications Issue 6
IEEE Std 1003.1, 2004 Edition
I suspect it has never, ever, ever been asked to delete anything that exists.
Also neither it, nor MCDelMsg() below free() the set and msg structures.
Found by Coverty SID:54
* Rename "config.h" to "nbtool_config.h" and
HAVE_CONFIG_H to HAVE_NBTOOL_CONFIG_H.
This makes in more obvious in the source when we're using
tools/compat/config.h versus "standard autoconf" config.h
* Consistently move the inclusion of nbtool_config.h to before
<sys/cdefs.h> so that the former can provide __RCSID() (et al),
and there's no need to protect those macros any more.
These changes should make it easier to "tool-ify" a program by adding:
#if HAVE_NBTOOL_CONFIG_H
#include "nbtool_config.h"
#endif
to the top of the source files (for the general case).
round has been tested on Solaris/x86 and Linux hosts.
* Add host tools cap_mkdb, ctags, m4, uudecode.
* Protect __RCSID() and __COPYRIGHT() better.
* Reduce the number of places that need to include "config.h", to keep
sources closer to their "vanilla" versions.
* Add more compat #defines and autoconf-checked functions.
.Sh SEE ALSO
rather than:
.Sh "SEE ALSO"
The former is the correct form, and it makes a (barely persceptible)
difference in formatting for some output devices (e.g. 'ps').