]> diplodocus.org Git - nmh/log
nmh
13 years agoFixed a couple of calls to m_getfld(): they were in while loops
David Levine [Sun, 27 Jan 2013 14:37:31 +0000 (08:37 -0600)]
Fixed a couple of calls to m_getfld():  they were in while loops
and the loop bodies were missing brackets.

13 years agoDeprecated msh(1).
David Levine [Sat, 26 Jan 2013 15:42:25 +0000 (09:42 -0600)]
Deprecated msh(1).

13 years agoIn build_nmh's output from the test suite: retain
David Levine [Sat, 26 Jan 2013 15:00:48 +0000 (09:00 -0600)]
In build_nmh's output from the test suite:  retain
colorization and list any test failures.

13 years agoEnabled colorized test output (PASS/FAIL/summary) by default
David Levine [Sat, 26 Jan 2013 14:52:50 +0000 (08:52 -0600)]
Enabled colorized test output (PASS/FAIL/summary) by default
via "color-tests" automake option.  To disable at runtime,
either set your AM_COLOR_TESTS environment variable to "no",
or provide that on the make check command line.

13 years agoReworked the new documentation in m_getfld.c.
David Levine [Sat, 26 Jan 2013 04:21:53 +0000 (22:21 -0600)]
Reworked the new documentation in m_getfld.c.

13 years agoHandle the case in the test suite where wcwidth() can return different
Ken Hornstein [Sat, 26 Jan 2013 03:22:46 +0000 (22:22 -0500)]
Handle the case in the test suite where wcwidth() can return different
values for combining Unicode codepoints on different operating systems.

13 years agoFix the format engine so it properly keeps track of multibyte characters
Ken Hornstein [Thu, 24 Jan 2013 21:05:36 +0000 (16:05 -0500)]
Fix the format engine so it properly keeps track of multibyte characters
and column positions when processing components and other functions.

When working on this code I realized we have nothing that checks to make
sure right justification of format function output works properly, so a
test for right justification is also included.

13 years agoAdded functions for inc, msh, rcvtty, and scan to access
David Levine [Thu, 24 Jan 2013 02:24:21 +0000 (20:24 -0600)]
Added functions for inc, msh, rcvtty, and scan to access
scansbr's gstate instance so it can be hidden, except for
msh's uses of m_getfld().

13 years agoFix a bug leading to message corruption with inc when incorporation more
Ken Hornstein [Mon, 21 Jan 2013 15:32:37 +0000 (10:32 -0500)]
Fix a bug leading to message corruption with inc when incorporation more
than one message at a time.

When I reworked the scan() code to remove the use of stdio internals,
two code paths were created.  The inc code path consumed another buffer
from the nxtbuf list for processing the message body.  At the end of
scan() there was code to push back all of the consumed buffers to the
nxtbuf list.  The extra buffer consumed in the inc code path wasn't
being pushed back, and as a result the nxtbuf list would end up with
duplicate pointers in it.  This would result in two components sharing
the same text buffer, which caused the message corruption.

When I looked at this closer, I realized that there was no reason to
push those buffers back to the list; nxtbuf gets reset to compbuffers
at the start of every call to scan(), and nxtbuf isn't used after the
buffers are pushed back.  Some researched revealed that this was the
same back in the original MH code.  I decided it was simplest to simply
delete the buffer recycling code.
(cherry picked from commit 22d2acba60374851c291260ff6aa716e9bf44a6d)

13 years agoBrought over changes to test-pop from master to m_getfld branch.
David Levine [Thu, 24 Jan 2013 01:42:56 +0000 (19:42 -0600)]
Brought over changes to test-pop from master to m_getfld branch.

13 years agoAdded scan and inc from mbox with multiple messages.
David Levine [Sun, 20 Jan 2013 14:38:18 +0000 (08:38 -0600)]
Added scan and inc from mbox with multiple messages.
(cherry picked from commit c4c53777458bfcfd288d45b7708e52eb47c56405)

13 years agoAdded test-msg-buffer-boundaries.
David Levine [Fri, 18 Jan 2013 02:58:25 +0000 (20:58 -0600)]
Added test-msg-buffer-boundaries.
(cherry picked from commit dbd0fa0a56a222bd118fea627eba53e5d9811d01)

13 years agoBrought over changes to test-pop from m_getfld branch.
David Levine [Thu, 24 Jan 2013 01:20:40 +0000 (19:20 -0600)]
Brought over changes to test-pop from m_getfld branch.

13 years agoChanged m_getfld() to automatically allocate a new state
David Levine [Wed, 23 Jan 2013 03:02:49 +0000 (21:02 -0600)]
Changed m_getfld() to automatically allocate a new state
instance as needed.  Callers no longer use
m_getfld_state_init().

13 years agoRemoved unnecessary m_getfld_state_destroy() from scan.c.
David Levine [Tue, 22 Jan 2013 23:08:21 +0000 (17:08 -0600)]
Removed unnecessary m_getfld_state_destroy() from scan.c.

13 years agoReworked enter_getfld() and Peek().
David Levine [Tue, 22 Jan 2013 23:07:47 +0000 (17:07 -0600)]
Reworked enter_getfld() and Peek().

13 years agoMerge branch 'master' into format-test
Ken Hornstein [Mon, 21 Jan 2013 15:58:07 +0000 (10:58 -0500)]
Merge branch 'master' into format-test

13 years agoFix a bug leading to message corruption with inc when incorporation more
Ken Hornstein [Mon, 21 Jan 2013 15:32:37 +0000 (10:32 -0500)]
Fix a bug leading to message corruption with inc when incorporation more
than one message at a time.

When I reworked the scan() code to remove the use of stdio internals,
two code paths were created.  The inc code path consumed another buffer
from the nxtbuf list for processing the message body.  At the end of
scan() there was code to push back all of the consumed buffers to the
nxtbuf list.  The extra buffer consumed in the inc code path wasn't
being pushed back, and as a result the nxtbuf list would end up with
duplicate pointers in it.  This would result in two components sharing
the same text buffer, which caused the message corruption.

When I looked at this closer, I realized that there was no reason to
push those buffers back to the list; nxtbuf gets reset to compbuffers
at the start of every call to scan(), and nxtbuf isn't used after the
buffers are pushed back.  Some researched revealed that this was the
same back in the original MH code.  I decided it was simplest to simply
delete the buffer recycling code.

13 years agoPlugged small memory leak in m_unknown().
David Levine [Mon, 21 Jan 2013 14:42:20 +0000 (08:42 -0600)]
Plugged small memory leak in m_unknown().

13 years agoReplaced hard-coded value with MAX_DELIMITER_SIZE in m_getfld.c.
David Levine [Mon, 21 Jan 2013 04:22:17 +0000 (22:22 -0600)]
Replaced hard-coded value with MAX_DELIMITER_SIZE in m_getfld.c.

13 years agoRemoved the static m_getfld() state instance and replaced
David Levine [Mon, 21 Jan 2013 03:27:54 +0000 (21:27 -0600)]
Removed the static m_getfld() state instance and replaced
with functions for callers to create and destroy their own
instances.  This also allows inc, msh, and pick to call
m_getfld() with an initial file stream position other than 0.

There is now a global state instance so that scan can call
m_unknown() on maildrop files.  It'd be nice to get rid of
that.

13 years agoFix memory leak in arglist code
Ken Hornstein [Mon, 21 Jan 2013 03:23:58 +0000 (22:23 -0500)]
Fix memory leak in arglist code

13 years agoAdded scan and inc from mbox with multiple messages.
David Levine [Sun, 20 Jan 2013 14:38:18 +0000 (08:38 -0600)]
Added scan and inc from mbox with multiple messages.

13 years agoUpdated test-inc-scanout on master to match version of
David Levine [Sun, 20 Jan 2013 13:49:58 +0000 (07:49 -0600)]
Updated test-inc-scanout on master to match version of
m_getfld branch.

13 years agoAdded a FILE * to the m_getfld_state struct so that most
David Levine [Sat, 19 Jan 2013 14:33:38 +0000 (08:33 -0600)]
Added a FILE * to the m_getfld_state struct so that most
functions don't need to pass it explicitly.  Note that
m_getfld() must still be passed the FILE * because some
callers, e.g., those in mhparse.c, reopen their input file
and therefore pass different FILE *'s for the same input.

13 years agoMoved all file static data in m_getfld.c into the
David Levine [Sat, 19 Jan 2013 14:00:03 +0000 (08:00 -0600)]
Moved all file static data in m_getfld.c into the
m_getfld_state struct.  Changed MSG_INPUT_SIZE from
hard-coded number to BUFSIZ.

13 years agoAdded check of -pack to test-pop.
David Levine [Sat, 19 Jan 2013 12:54:10 +0000 (06:54 -0600)]
Added check of -pack to test-pop.

13 years agoFixed test-header to work on Cygwin, which has a BUFSIZ of
David Levine [Sat, 19 Jan 2013 01:19:00 +0000 (19:19 -0600)]
Fixed test-header to work on Cygwin, which has a BUFSIZ of
only 1024.  That caused an error message to be truncated.

13 years agoBeginning of implementation of new argsplit() function to handle arguments
Ken Hornstein [Fri, 18 Jan 2013 21:03:26 +0000 (16:03 -0500)]
Beginning of implementation of new argsplit() function to handle arguments
to profile-defined commands.

13 years agoRemoved all traces of m_getfld() FLDEOF and BODYEOF states.
David Levine [Fri, 18 Jan 2013 03:58:50 +0000 (21:58 -0600)]
Removed all traces of m_getfld() FLDEOF and BODYEOF states.
They were never set by m_getfld(), so all caller code that
supported them was completely unexercised.

13 years agoMinimized message files reads in m_getfld() when the caller
David Levine [Fri, 18 Jan 2013 03:46:54 +0000 (21:46 -0600)]
Minimized message files reads in m_getfld() when the caller
interleaves calls to fseek().  Added check of handling of
long header field name without a colon to test-header.

13 years agoAdded test-msg-buffer-boundaries.
David Levine [Fri, 18 Jan 2013 02:58:25 +0000 (20:58 -0600)]
Added test-msg-buffer-boundaries.

13 years agoMore cleanup of m_getfld(), changed some variable names.
David Levine [Thu, 17 Jan 2013 04:02:12 +0000 (22:02 -0600)]
More cleanup of m_getfld(), changed some variable names.

13 years agoAdded check of header field body with more than 511
David Levine [Thu, 17 Jan 2013 03:48:11 +0000 (21:48 -0600)]
Added check of header field body with more than 511
characters to test-inc-scanout.  Also changed a couple of
test message files to be generated on the fly.

13 years agoCleaned up m_getfld() code a bit. The most notable change
David Levine [Thu, 17 Jan 2013 02:13:04 +0000 (20:13 -0600)]
Cleaned up m_getfld() code a bit.  The most notable change
was to remove the check for mmdlm2 not being null.  It's
global data so that shouldn't happen.

13 years agoAdded check of a header with name that's 998 bytes long to
David Levine [Wed, 16 Jan 2013 04:56:33 +0000 (22:56 -0600)]
Added check of a header with name that's 998 bytes long to
test-header.

13 years agoRemoved the for-loop that was used to get a header field
David Levine [Wed, 16 Jan 2013 02:11:41 +0000 (20:11 -0600)]
Removed the for-loop that was used to get a header field
name in m_getfld ().  It was no longer necessary when not
drawing directly from the stdio buffer.

13 years agoCheck that a character array isn't empty before looking for its
David Levine [Wed, 16 Jan 2013 01:38:16 +0000 (19:38 -0600)]
Check that a character array isn't empty before looking for its
next-to-last element.

13 years agoIn build_nmh, removed configuration of pager and editor.
David Levine [Wed, 16 Jan 2013 00:14:46 +0000 (18:14 -0600)]
In build_nmh, removed configuration of pager and editor.
And replaced use of which(1) with a self-contained function.

13 years agoSupport the VISUAL and EDITOR environment variables, and remove support
Ken Hornstein [Tue, 15 Jan 2013 20:30:17 +0000 (15:30 -0500)]
Support the VISUAL and EDITOR environment variables, and remove support
for configuring a default editor with --with-editor.

13 years agoRemove the --with-pager configure option and replace it with a default
Ken Hornstein [Tue, 15 Jan 2013 18:22:13 +0000 (13:22 -0500)]
Remove the --with-pager configure option and replace it with a default
of "more".

13 years agoRenamed a couple of m_getfld auxiliary functions.
David Levine [Tue, 15 Jan 2013 04:05:38 +0000 (22:05 -0600)]
Renamed a couple of m_getfld auxiliary functions.

13 years agoCleaned up m_getfld's read_more().
David Levine [Tue, 15 Jan 2013 03:34:08 +0000 (21:34 -0600)]
Cleaned up m_getfld's read_more().

13 years agoIn m_getfld(), fixed the loop that handles the FLDPLUS case.
David Levine [Tue, 15 Jan 2013 03:05:22 +0000 (21:05 -0600)]
In m_getfld(), fixed the loop that handles the FLDPLUS case.
In Getc(), removed the increment of the byte count at EOF,
it didn't seem correct or necessary.

13 years agom_getfld() now supports interleaving calls with
David Levine [Tue, 15 Jan 2013 02:58:56 +0000 (20:58 -0600)]
m_getfld() now supports interleaving calls with
fseek()/ftell().  Reverted the changes to uip/mhparse.c of
commit 484eb1003ae647e4b751e4d7829c7daf44fb99c9 because
they're no longer necessary.

13 years agoMoved test of empty header field from
David Levine [Mon, 14 Jan 2013 15:45:23 +0000 (09:45 -0600)]
Moved test of empty header field from
test/inc/test-inc-scanout to test/bad-input/test-header.

13 years agoCleaned up a bit.
David Levine [Mon, 14 Jan 2013 15:41:50 +0000 (09:41 -0600)]
Cleaned up a bit.

13 years agoAdded support for m_getfld() callers interleaving fseek() calls
David Levine [Mon, 14 Jan 2013 03:56:07 +0000 (21:56 -0600)]
Added support for m_getfld() callers interleaving fseek() calls
with their m_getfld() calls.

13 years agoAdded bytes_read to m_getfld() buffer state. This is the
David Levine [Sun, 13 Jan 2013 17:08:28 +0000 (11:08 -0600)]
Added bytes_read to m_getfld() buffer state.  This is the
next step in supporting ftell()/fseek().

13 years agoRemoved unused local char_read from forwsbr.c.
David Levine [Sun, 13 Jan 2013 15:43:15 +0000 (09:43 -0600)]
Removed unused local char_read from forwsbr.c.

13 years agoAdded check of m_getfld() handling of fields with trailing
David Levine [Sun, 13 Jan 2013 15:17:47 +0000 (09:17 -0600)]
Added check of m_getfld() handling of fields with trailing
whitespace to test-inc-scanout.'

13 years agoRemoved "sleazy hack" of negative bufsz because commit
David Levine [Sat, 12 Jan 2013 17:14:45 +0000 (11:14 -0600)]
Removed "sleazy hack" of negative bufsz because commit
05d8af21d26673279a1ca079ad9c6f301426fe0e removed the only
use of it.

13 years agoCleaned up FLDPLUS handling in m_getfld(). As part of this,
David Levine [Sat, 12 Jan 2013 16:58:31 +0000 (10:58 -0600)]
Cleaned up FLDPLUS handling in m_getfld().  As part of this,
removed the backing up of the read pointer in the "something
went wrong" portion of the FLD handling.  It had been moved
back two positions.  The first is no longer necessary
because a Getc() was replace by a Peek(), and the second
caused the extra blank line noted in the old comments.
Updated the expected output in test/bad-input/test-header to
correspond.

13 years agoFixed addition to test-inc-scanout in
David Levine [Sat, 12 Jan 2013 15:23:19 +0000 (09:23 -0600)]
Fixed addition to test-inc-scanout in
683e0fb1a14da5b9ce7bc5db6e76951d14d79348 to not depend on
current date.

13 years agoVery minor cleanup to m_getfld() to remove an increment of j.
David Levine [Sat, 12 Jan 2013 15:21:59 +0000 (09:21 -0600)]
Very minor cleanup to m_getfld() to remove an increment of j.

13 years agoWe never use the autoconf checks for errno.h, crypt.h, or netdb.h, so
Ken Hornstein [Fri, 11 Jan 2013 16:13:44 +0000 (11:13 -0500)]
We never use the autoconf checks for errno.h, crypt.h, or netdb.h, so
remove them.

13 years agoAt this point we're assuming at least C89 support, so there's no reason
Ken Hornstein [Fri, 11 Jan 2013 16:07:51 +0000 (11:07 -0500)]
At this point we're assuming at least C89 support, so there's no reason
we should check for support for const and standard header files.

13 years agoStarted revising m_getfld() code to replace direct buffer
David Levine [Fri, 11 Jan 2013 04:52:59 +0000 (22:52 -0600)]
Started revising m_getfld() code to replace direct buffer
access with Getc().  The goal is to again support fseek()
after return from m_getfld().

13 years agoConvert the MIME content cache switches over to the smatch() New World Order.
Ken Hornstein [Thu, 10 Jan 2013 19:18:15 +0000 (14:18 -0500)]
Convert the MIME content cache switches over to the smatch() New World Order.

13 years agoAdded explicit third initializer to some swit struct values
David Levine [Thu, 10 Jan 2013 14:00:20 +0000 (08:00 -0600)]
Added explicit third initializer to some swit struct values
to silence gcc -Wmissing-field-initialziers warning.

13 years agoConvert all argument processing over to using X-Macros for cleanup.
Ken Hornstein [Thu, 10 Jan 2013 03:04:23 +0000 (22:04 -0500)]
Convert all argument processing over to using X-Macros for cleanup.
Based on a suggestion by Ralph Corderoy.

13 years agoAdded comments to and started cleaning up m_getfld.c.
David Levine [Thu, 10 Jan 2013 02:58:03 +0000 (20:58 -0600)]
Added comments to and started cleaning up m_getfld.c.

13 years agoWhen read_more() loads more bytes, save some from the end of the
David Levine [Thu, 10 Jan 2013 02:50:58 +0000 (20:50 -0600)]
When read_more() loads more bytes, save some from the end of the
current chunk and move them to the front of the buffer.  This
allows backing up of the current position, which is necessary when
looking for the message delimiter in a maildrop file.

13 years agoFix bug where a "cur" sequence that was outside the folder allocation limits
Ken Hornstein [Mon, 7 Jan 2013 22:41:27 +0000 (17:41 -0500)]
Fix bug where a "cur" sequence that was outside the folder allocation limits
could trigger a core dump on some systems.

13 years agoRemoved support for #ifdef LBL. It was broken anyways,
David Levine [Sun, 6 Jan 2013 21:04:24 +0000 (15:04 -0600)]
Removed support for #ifdef LBL.  It was broken anyways,
sometime between MH 6.8.5 and the Apr 1999 entry into CVS.
Also removed the addtoseq format function that could only be
accessed with it.

13 years agoFixed test-utf8-body to actually contain the UTF-8 character
David Levine [Sun, 6 Jan 2013 15:38:21 +0000 (09:38 -0600)]
Fixed test-utf8-body to actually contain the UTF-8 character
instead of the single byte, 8-bit character.  This was caught
using Heirloom shell with a UTF-8 locale:  when it wrote the
test draft from a here document, it converted the single byte
character to UTF-8.  This verifies that behavior:

LANG=en_US.utf-8 /usr/lib/heirloom/5bin/sh -c "od -x <<EOF
`printf '\xA1'`
EOF
"

13 years agoExpanded warning message for invalid Content-Transfer-Encoding.
David Levine [Sat, 5 Jan 2013 15:55:35 +0000 (09:55 -0600)]
Expanded warning message for invalid Content-Transfer-Encoding.

13 years agoAdded reference to RFC-1864 to mhbuild man page.
David Levine [Sat, 5 Jan 2013 00:50:06 +0000 (18:50 -0600)]
Added reference to RFC-1864 to mhbuild man page.

13 years agoRemove support for -ebcdicsafe/-noebcdicsafe switches in various utilities.
Ken Hornstein [Fri, 4 Jan 2013 20:12:15 +0000 (15:12 -0500)]
Remove support for -ebcdicsafe/-noebcdicsafe switches in various utilities.

13 years agoCreate a dependency for mh-chart.man on all of the man page sources so
Ken Hornstein [Fri, 4 Jan 2013 20:03:32 +0000 (15:03 -0500)]
Create a dependency for mh-chart.man on all of the man page sources so
it gets rebuilt correctly if the man pages change.

13 years agoBlock SIGPIPE before killing the child in sm_end(). This replaces
David Levine [Fri, 4 Jan 2013 04:33:42 +0000 (22:33 -0600)]
Block SIGPIPE before killing the child in sm_end().  This replaces
the discard() calls that were removed in commit 4548a3ecc4248a1d4.

13 years agoRemoved discard() call in post(8). It was only used with -debug
David Levine [Fri, 4 Jan 2013 04:32:28 +0000 (22:32 -0600)]
Removed discard() call in post(8).  It was only used with -debug
and seemed to serve no useful purpose any more.  Its comment
said that it was needed to help the loader.

13 years agoIn cpstripped() and cptrimmed(), if a multibyte character is
David Levine [Fri, 4 Jan 2013 03:59:44 +0000 (21:59 -0600)]
In cpstripped() and cptrimmed(), if a multibyte character is
found, only count it as taking up one character in the
destination buffer (if it has enought room).  This way,
scan(1)'s output won't be jagged if there are any subjects,
for example, that have multibyte characters.

Added a test for this to test-scan-multibyte, and moved the
test for an invalid multibyte sequence from test-scan to it.

13 years agoRemoved empty file name .null from the historical mh-6.8.5 tree.
David Levine [Fri, 4 Jan 2013 03:51:56 +0000 (21:51 -0600)]
Removed empty file name .null from the historical mh-6.8.5 tree.

13 years agoFixed decoding of header fields when they contain a character that
David Levine [Thu, 3 Jan 2013 02:07:43 +0000 (20:07 -0600)]
Fixed decoding of header fields when they contain a character that
can't be converted.  Added test case to test-scan.  valgrind also
noticed that things went amiss.

13 years agoRemove test .netrc file at the end of test-pop.
David Levine [Thu, 3 Jan 2013 00:13:59 +0000 (18:13 -0600)]
Remove test .netrc file at the end of test-pop.

13 years agoSwitch to using native automake rules for cscope.
Ken Hornstein [Wed, 2 Jan 2013 20:23:29 +0000 (15:23 -0500)]
Switch to using native automake rules for cscope.

13 years agoChange TLS support to only link the TLS libraries with the programs that
Ken Hornstein [Wed, 2 Jan 2013 03:06:33 +0000 (22:06 -0500)]
Change TLS support to only link the TLS libraries with the programs that
need them.

13 years agoClean up (and hopefully improve) the autoconf iconv tests.
Ken Hornstein [Tue, 1 Jan 2013 07:40:30 +0000 (02:40 -0500)]
Clean up (and hopefully improve) the autoconf iconv tests.

13 years agoStill MORE autoconf cleanup.
Ken Hornstein [Tue, 1 Jan 2013 06:50:06 +0000 (01:50 -0500)]
Still MORE autoconf cleanup.

13 years agoAutoconf/automake cleanup
Ken Hornstein [Tue, 1 Jan 2013 06:27:08 +0000 (01:27 -0500)]
Autoconf/automake cleanup

13 years agoDocument removal of --enable-nmh-debug
Ken Hornstein [Tue, 1 Jan 2013 06:01:32 +0000 (01:01 -0500)]
Document removal of --enable-nmh-debug

13 years agoFinally deprecate --enable-nmh-debug
Ken Hornstein [Tue, 1 Jan 2013 06:00:03 +0000 (01:00 -0500)]
Finally deprecate --enable-nmh-debug

13 years agoNote changes to autoconf requirements here.
Ken Hornstein [Mon, 31 Dec 2012 01:17:01 +0000 (20:17 -0500)]
Note changes to autoconf requirements here.

13 years agoWe are now requiring autoconf 2.68 and automake 1.13.
Ken Hornstein [Mon, 31 Dec 2012 00:40:42 +0000 (19:40 -0500)]
We are now requiring autoconf 2.68 and automake 1.13.

13 years agoNote that the minimum required version of automake is 1.12.
Lyndon Nerenberg [Sun, 30 Dec 2012 20:19:47 +0000 (12:19 -0800)]
Note that the minimum required version of automake is 1.12.

13 years agoIgnore top-level ar-lib file.
Lyndon Nerenberg [Sun, 30 Dec 2012 17:38:46 +0000 (09:38 -0800)]
Ignore top-level ar-lib file.

This is detritus from the AM_PROG_AR macro I added to configure.ac.

13 years agoAdd an AM_PROG_AR program check to configure.ac This quells a
Lyndon Nerenberg [Sun, 30 Dec 2012 09:27:49 +0000 (01:27 -0800)]
Add an AM_PROG_AR program check to configure.ac  This quells a
warning when configuring on FreeBSD 10.

13 years agoCorrected fseek() emulation to fix test/bad-input/test-header.
David Levine [Thu, 27 Dec 2012 19:53:33 +0000 (13:53 -0600)]
Corrected fseek() emulation to fix test/bad-input/test-header.

13 years agoReplace use of ftell() in mhparse.c:get_content() by keeping track
David Levine [Thu, 27 Dec 2012 15:51:09 +0000 (09:51 -0600)]
Replace use of ftell() in mhparse.c:get_content() by keeping track
of bytes read by m_getfld().

13 years agoTweaked last commit to test/common.sh.in to eliminate a mv.
David Levine [Wed, 26 Dec 2012 20:03:20 +0000 (14:03 -0600)]
Tweaked last commit to test/common.sh.in to eliminate a mv.

13 years agoAdded note about PATH when running "make check" on Cygwin.
David Levine [Wed, 26 Dec 2012 17:09:28 +0000 (11:09 -0600)]
Added note about PATH when running "make check" on Cygwin.

13 years agoFixed test-slocal to work with mmdfldir set to /dev/null, and on
David Levine [Wed, 26 Dec 2012 17:04:23 +0000 (11:04 -0600)]
Fixed test-slocal to work with mmdfldir set to /dev/null, and on
Cygwin, which needs the full path to tee(1).

13 years agoRestored an explicit refill of the buffer in m_getfld() that I
David Levine [Wed, 26 Dec 2012 15:52:12 +0000 (09:52 -0600)]
Restored an explicit refill of the buffer in m_getfld() that I
removed in the big stdio cleanup.  Its need is shown by reducing
the message buffer size to 2048.

13 years agoRemoved call to fpurge() and its platform-specific emulations
David Levine [Wed, 26 Dec 2012 01:25:43 +0000 (19:25 -0600)]
Removed call to fpurge() and its platform-specific emulations
from discard.c.  discard() is called on stdout from mhl(1) and
msh(1) in interrupt handlers, and post(8) but only with -debug.
tcflush() should do the purge when stdout is a terminal.  If
it's a file or pipe, well, maybe some garbage could get flushed
out.  And it's called on the streams that post uses to talk to
its smtp server, so removed those calls because they no longer
do anything.  And removed LINUX_STDIO define from configure.ac.

13 years agoReplaced all the stdio buffer access in m_getfld.c with a single call
David Levine [Tue, 25 Dec 2012 17:57:31 +0000 (11:57 -0600)]
Replaced all the stdio buffer access in m_getfld.c with a single call
to fread() and then some almost straightforward buffer manipulations.

13 years agoFixed formatting of last change to scansbr.c.
David Levine [Tue, 25 Dec 2012 17:57:02 +0000 (11:57 -0600)]
Fixed formatting of last change to scansbr.c.

13 years agoUpdated m_getfld() interface description.
David Levine [Sun, 23 Dec 2012 15:27:03 +0000 (09:27 -0600)]
Updated m_getfld() interface description.

13 years agoChanged bufsz argument of m_getfld() to be in-out instead of in.
David Levine [Sat, 22 Dec 2012 17:51:21 +0000 (11:51 -0600)]
Changed bufsz argument of m_getfld() to be in-out instead of in.
This allowed removal of the msg_count global, in turn allowing
removal of sbr/m_msgdef.c

13 years agoChanged msg_style and msg_delim to be file static to m_getfld.c
David Levine [Sat, 22 Dec 2012 16:14:36 +0000 (10:14 -0600)]
Changed msg_style and msg_delim to be file static to m_getfld.c
instead of global.