The problem is that mime_decode_close() closes all files registered
after mip->mi_pipe_end and this is getting set in mime_sendmessage()
after a fflush().
When you print a large number of messages fflush() blocks and prevents
mip->mi_pipe_end from getting set before the SIGPIPE comes in and
jumps to the close block that calls mime_decode_close(). As a result,
mime_decode_close() was closing all the registered files including
obuf (mi_pipe_end was NULL).
1) Removed the -B flag (it was stupid on my part) and added a short
description indicating how to accomplish the same thing under the
"Sending Mail" section of man mail(1).
2) Added a -H flag to dump the headers and exit. It takes optional
flags to restrict to old, new, read, unread, and deleted messages
(the later being kind of useless - it shares code with something
that already had it).
3) Restored the 'Save' command which somehow got mistakenly removed in
the last commit and add documentation for it! (My apologies to
its author.)
4) Added a 'mkread' command to mark messages as read (the inverse of
'unread'). Should we also have a 'mknew' command?
5) Added a 'smopts' command to keep a database of addresses and
sendmail options to be used when sending messages to those
addresses. See man mail(1) for a fuller description.
6) Added 'indentpreamble' and 'indentpostscript' variables whose
values are inserted before and after a quoted message (~m or ~M
escapes).
=20
7) Added string formatting abilities for the 'prompt', 'insertpreamble',
'insertpostscript', and header display strings. These strings
support all the strftime() format parameters as well as many more
specific to mail (see man mail(1)).
8) Fix the -a flag so that it only takes a single filename, unless
"mime-attach-list" is defined. This is more conventional and avoids
unexpected whitespace issues.
* Add history file to save search and shell command history between
invocations of less.
* Improve behavior of history list for search and shell commands.
* Add -K (or --quit-on-intr) option to make less exit immediately on ctrl-C.
* Improve handling of UTF-8 files and commands, including better
line wrapping and handling double-width chars.
* Added LESSUTFBINFMT environment variable to control display of
non-printable characters in a UTF-8 file.
* Add --with-secure option to configure, to make it easier to
build a secure version of less.
* Show search matches in the status column even if search highlights
are disabled via the -G option or the ESC-u command.
* Improve performance when the file contains very long lines.
* Add "windows" charset.
* Add man page for lessecho.
* Add support for erase2 character, treated same as erase.
* Use ASCII lowercase/uppercase logic when operating on the command line.
* Update makefile for Borland C++ 5.5.1.
* Fix bug in calculating number of pages for %D prompt.
* Fix bug in handling tag file error.
* Fix obscure bug if input file is deleted while viewing help.
* Fix bug handling filenames which include square brackets.
* Fix possible buffer overflow in "global" tag search.
* Fix possible buffer overflow in usage of LESSOPEN and LESSCLOSE.
* Fix buffer overflow in reverse search.
* Removed some old copyrighted code.
This probably breaks OS/9 support.
* Add history file to save search and shell command history between
invocations of less.
* Improve behavior of history list for search and shell commands.
* Add -K (or --quit-on-intr) option to make less exit immediately on ctrl-C.
* Improve handling of UTF-8 files and commands, including better
line wrapping and handling double-width chars.
* Added LESSUTFBINFMT environment variable to control display of
non-printable characters in a UTF-8 file.
* Add --with-secure option to configure, to make it easier to
build a secure version of less.
* Show search matches in the status column even if search highlights
are disabled via the -G option or the ESC-u command.
* Improve performance when the file contains very long lines.
* Add "windows" charset.
* Add man page for lessecho.
* Add support for erase2 character, treated same as erase.
* Use ASCII lowercase/uppercase logic when operating on the command line.
* Update makefile for Borland C++ 5.5.1.
* Fix bug in calculating number of pages for %D prompt.
* Fix bug in handling tag file error.
* Fix obscure bug if input file is deleted while viewing help.
* Fix bug handling filenames which include square brackets.
* Fix possible buffer overflow in "global" tag search.
* Fix possible buffer overflow in usage of LESSOPEN and LESSCLOSE.
* Fix buffer overflow in reverse search.
* Removed some old copyrighted code.
This probably breaks OS/9 support.
globbing.
The old behaviour was the perform variable expansion and globbing on the
output of both the variable expansion and globbing. Which allows some very
strange behaviour if, for example, globbed filenames contain $ symbols.
Unconditionally add new nodes from these expansions even if the names are
already children. The .WAIT code needs the order of children preserved.
part of PR bin/26860 by Michael van Elst
while here, put output file fopen() inside the code block of the
only code path where it's actually needed, to make the logic more obvious;
and in the "stdout" case, initialize toutpath to empty string rather
then /dev/stdout, to make it clear /dev/stdout is not actually used
Fix PR port-sparc64/34863.
This also caused warning on old NetBSD environments (with GNU awk) like
awk: cmd. line:80: warning: escape sequence `\#' treated as plain `#'
INTPTR_IS_LONG, not INTPTR_IS_ULONG -- the latter is unused in
other parts of lint's code. This stops vax's lint from complaining
about conversion of integer constants to 'unsigned long' in function
argument lists, via a proper define of INT_RSIZE in common/inittyp.c.
sh3 defined this to 0, so was actually not affected, but better to
eradicate the typo there as well.
SPECIAL prog {objs,objpaths,keepsymbols} itemX
lines (where "prog" is fixed) in crunchgen configuration the same as
SPECIAL prog {objs,objpaths,keepsymbols} item1 ... itemN
OK by David Laight
Remove the apparently always true "styp(nt) != SHORT" part of the
innermost test. Allow atomatic conversion of literals as long as
they fit into the target type.
This should fix some of the lint issues in proplib on some of our
platforms.
Approved by christos.
targets integer data type value ranges. For now we just use the
hosts uint64_t for parsing & storing integers constants, and test
against the targets limits and assign appropriately, instead of
sometimes (inappropriately) going via the hosts u_long type. As
long as none of our architectures have target long or quad data
types strictly larger than 64 bits, we should be fine with this
fix.
Furthermore, as they stand at the moment, we can't use the current
TARG_INT_MAX and TARG_LONG_MAX constants in C preprocessor expressions,
so remove the conditional on them being equal. Yes, this will
produce dead code for some targets.
This allows an ilp32 host to lint for an lp64 target which uses
e.g. the targets ULONG_MAX constant without triggering an "integer
constant out of range" warning.
OK'ed by christos.
Rename 'allsrc' to 'curSrcs' so that the variable passed to ParseDoSrc (etc)
has the same name as the local in the calling routine, rather than a name
that seems to imply a more global and persistent list.
- don't blindly walk before the beginning of the buffer because of a
corrupt dependency file. In this case the first character of the
dependency file was a :
loop continue part. Remove the 'free(line)' from teh end of the loop body,
change the gotos into continues and collapse out some 'else if's.
All in the name of code transparency. No functional changes.
(Almost all the debug output went there, but some went to stderr.)
Split the parsing of -d (debug flags) out into its own routine.
Allow the output filename to be changed by specifying -dF<file> to create
a log file, or -dF+<file> to append to it. <file> may be stdout or stderr.
Also change so that -d-<flags> acts on <flags> locally but doesn't copy
them to MAKEFLAGS so they aren't inherited by child makes.
I'm not 100% happy with the command line syntax for the above, so they are
currently undocumented.