[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[SCM] GNU Mailutils branch, master, updated. release-2.2-628-g1cbbd57
From: |
Sergey Poznyakoff |
Subject: |
[SCM] GNU Mailutils branch, master, updated. release-2.2-628-g1cbbd57 |
Date: |
Sun, 05 Aug 2012 13:04:57 +0000 |
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GNU Mailutils".
http://git.savannah.gnu.org/cgit/mailutils.git/commit/?id=1cbbd572d56b7a77362992181ef008db8a11688f
The branch, master has been updated
via 1cbbd572d56b7a77362992181ef008db8a11688f (commit)
from 6e2a37582ae89b43438952059412ea4a994d546c (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit 1cbbd572d56b7a77362992181ef008db8a11688f
Author: Sergey Poznyakoff <address@hidden>
Date: Sat Aug 4 20:04:01 2012 +0300
Ensure consisten stream state before calling its ctl method.
Prior to calling ctl method, mu_stream_ioctl flushes stream
buffer.
* libmailutils/stream/fltstream.c (filter_ctl)
<MU_IOCTL_FILTER_SET_DISABLED>: Flush internal buffer prior to
setting the flag.
* libmailutils/stream/stream.c (mu_stream_ioctl): Flush stream
buffer.
-----------------------------------------------------------------------
Summary of changes:
libmailutils/stream/fltstream.c | 5 +++++
libmailutils/stream/stream.c | 3 +++
2 files changed, 8 insertions(+), 0 deletions(-)
diff --git a/libmailutils/stream/fltstream.c b/libmailutils/stream/fltstream.c
index 9a8e4b5..36e9c5e 100644
--- a/libmailutils/stream/fltstream.c
+++ b/libmailutils/stream/fltstream.c
@@ -399,6 +399,7 @@ filter_ctl (struct _mu_stream *stream, int code, int
opcode, void *ptr)
{
struct _mu_filter_stream *fs = (struct _mu_filter_stream *)stream;
int status;
+ size_t dummy;
switch (code)
{
@@ -406,6 +407,10 @@ filter_ctl (struct _mu_stream *stream, int code, int
opcode, void *ptr)
switch (opcode)
{
case MU_IOCTL_FILTER_SET_DISABLED:
+ status = filter_write_internal (stream, mu_filter_flush,
+ NULL, 0, &dummy);
+ if (status)
+ return status;
if (ptr && *(int*)ptr)
fs->fltflag |= _MU_FILTER_DISABLED;
else
diff --git a/libmailutils/stream/stream.c b/libmailutils/stream/stream.c
index 7272269..a7dabbf 100644
--- a/libmailutils/stream/stream.c
+++ b/libmailutils/stream/stream.c
@@ -1156,7 +1156,10 @@ mu_stream_size (mu_stream_t stream, mu_off_t *psize)
int
mu_stream_ioctl (mu_stream_t stream, int family, int opcode, void *ptr)
{
+ int rc;
_bootstrap_event (stream);
+ if ((rc = _stream_flush_buffer (stream, _MU_STR_FLUSH_ALL)))
+ return rc;
if (stream->ctl == NULL)
return ENOSYS;
return stream->ctl (stream, family, opcode, ptr);
hooks/post-receive
--
GNU Mailutils
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [SCM] GNU Mailutils branch, master, updated. release-2.2-628-g1cbbd57,
Sergey Poznyakoff <=