[SCM] GNU Mailutils branch, master, updated. release-2.2-797-gb48ac92
"Sergey Poznyakoff" <[email protected]> Fri, 28 Oct 2016 17:23:12 +0000 (UTC)
| Newsgroups | gmane.comp.gnu.mailutils.cvs |
|---|---|
| Message-ID | <[email protected]> |
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=b48ac923058cb1967209ee2883d93d55932a0364
The branch, master has been updated
via b48ac923058cb1967209ee2883d93d55932a0364 (commit)
from a6bd9b68b90e7c106d9021aaa83c2b3c82809b18 (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 b48ac923058cb1967209ee2883d93d55932a0364
Author: Sergey Poznyakoff <[email protected]>
Date: Fri Oct 28 20:05:06 2016 +0300
Bugfix
* configure.ac: Version 2.99.992
* NEWS: Update.
* libmailutils/opt/opt.c (add_option_cache): Use opt_default if
no argument is given.
-----------------------------------------------------------------------
Summary of changes:
NEWS | 4 ++--
configure.ac | 2 +-
libmailutils/opt/opt.c | 6 ++++++
3 files changed, 9 insertions(+), 3 deletions(-)
diff --git a/NEWS b/NEWS
index 7ebc72a..40768fa 100644
--- a/NEWS
+++ b/NEWS
@@ -1,11 +1,11 @@
-GNU mailutils NEWS -- history of user-visible changes. 2016-10-19
+GNU mailutils NEWS -- history of user-visible changes. 2016-10-28
Copyright (C) 2002-2016 Free Software Foundation, Inc.
See the end of file for copying conditions.
Please send mailutils bug reports to <[email protected]>.
-Version 2.99.991 (Git)
+Version 2.99.992 (Git)
This version is a major rewrite of GNU Mailutils. Quite a few parts
of the basic framework were rewritten from scratch, while some others
diff --git a/configure.ac b/configure.ac
index 5fd7d85..4b88e6c 100644
--- a/configure.ac
+++ b/configure.ac
@@ -16,7 +16,7 @@ dnl You should have received a copy of the GNU General Public License along
dnl with GNU Mailutils. If not, see <http://www.gnu.org/licenses/>.
AC_PREREQ(2.63)
-AC_INIT([GNU Mailutils], [2.99.991], [[email protected]], [mailutils],
+AC_INIT([GNU Mailutils], [2.99.992], [[email protected]], [mailutils],
[http://mailutils.org])
AC_CONFIG_SRCDIR([libmailutils/mailbox/mailbox.c])
AC_CONFIG_AUX_DIR([build-aux])
diff --git a/libmailutils/opt/opt.c b/libmailutils/opt/opt.c
index 26633bb..0a436c5 100644
--- a/libmailutils/opt/opt.c
+++ b/libmailutils/opt/opt.c
@@ -148,7 +148,10 @@ add_option_cache (struct mu_parseopt *po, struct mu_option *opt,
char const *arg)
{
struct mu_option_cache *cache = mu_alloc (sizeof (*cache));
+
cache->cache_opt = opt;
+ if (arg == NULL && opt->opt_default)
+ arg = opt->opt_default;
cache->cache_arg = arg;
if ((po->po_flags & MU_PARSEOPT_IMMEDIATE)
@@ -749,6 +752,9 @@ mu_option_set_value (struct mu_parseopt *po, struct mu_option *opt,
if (arg == NULL)
{
if (opt->opt_default)
+ /* The default value has been already assigned in add_option_cache.
+ This conditional is here in case mu_option_set_value is called
+ from the user code. */
arg = opt->opt_default;
else if (opt->opt_arg == NULL)
arg = "1";
hooks/post-receive
--
GNU Mailutils