* [Openvpn-devel] [PATCH] Warn when using verb levels >=7 without debug
@ 2013-03-20 16:32 Josh Cepek
2013-03-20 16:42 ` Arne Schwabe
0 siblings, 1 reply; 5+ messages in thread
From: Josh Cepek @ 2013-03-20 16:32 UTC (permalink / raw)
To: openvpn-devel
This patch adds a log warning when using --verb levels at 7 or higher
when running on builds lacking debug support. Since official builds are
now built with enable_debug=no, this warning will help developers
identify why expected debug messages may not be present in log output.
The test and message output code is omitted when built with
enable_debug=yes or enable_small=yes.
Signed-off-by: Josh Cepek <josh.cepek@...1085...>
---
src/openvpn/options.c | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/src/openvpn/options.c b/src/openvpn/options.c
index 2eb4f91..7f8940c 100644
--- a/src/openvpn/options.c
+++ b/src/openvpn/options.c
@@ -4672,6 +4672,12 @@ add_option (struct options *options,
{
VERIFY_PERMISSION (OPT_P_MESSAGES);
options->verbosity = positive_atoi (p[1]);
+#if !defined(ENABLE_DEBUG) && !defined(ENABLE_SMALL)
+ /* Warn when a debug verbosity is supplied when built without debug support */
+ if (options->verbosity >= 7)
+ msg (M_WARN, "NOTE: a debug verb level (--verb %d) is enabled, but this build lacks debug support.",
+ options->verbosity);
+#endif
}
else if (streq (p[0], "mute") && p[1])
{
--
1.7.12.4
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [Openvpn-devel] [PATCH] Warn when using verb levels >=7 without debug
2013-03-20 16:32 [Openvpn-devel] [PATCH] Warn when using verb levels >=7 without debug Josh Cepek
@ 2013-03-20 16:42 ` Arne Schwabe
2013-03-20 18:22 ` [Openvpn-devel] (updated) " Josh Cepek
0 siblings, 1 reply; 5+ messages in thread
From: Arne Schwabe @ 2013-03-20 16:42 UTC (permalink / raw)
To: Josh Cepek <josh.cepek@; +Cc: openvpn-devel
Am 20.03.13 17:32, schrieb Josh Cepek:
> This patch adds a log warning when using --verb levels at 7 or higher
> when running on builds lacking debug support. Since official builds are
> now built with enable_debug=no, this warning will help developers
> identify why expected debug messages may not be present in log output.
>
> The test and message output code is omitted when built with
> enable_debug=yes or enable_small=yes.
>
> Signed-off-by: Josh Cepek <josh.cepek@...1085...>
> ---
> src/openvpn/options.c | 6 ++++++
> 1 file changed, 6 insertions(+)
>
> diff --git a/src/openvpn/options.c b/src/openvpn/options.c
> index 2eb4f91..7f8940c 100644
> --- a/src/openvpn/options.c
> +++ b/src/openvpn/options.c
> @@ -4672,6 +4672,12 @@ add_option (struct options *options,
> {
> VERIFY_PERMISSION (OPT_P_MESSAGES);
> options->verbosity = positive_atoi (p[1]);
> +#if !defined(ENABLE_DEBUG) && !defined(ENABLE_SMALL)
> + /* Warn when a debug verbosity is supplied when built without debug support */
> + if (options->verbosity >= 7)
> + msg (M_WARN, "NOTE: a debug verb level (--verb %d) is enabled, but this build lacks debug support.",
> + options->verbosity);
> +#endif
> }
> else if (streq (p[0], "mute") && p[1])
> {
ACK. But I would change "debug verb" to "debug verbosity" and I think
there should be no comma before "but"
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [Openvpn-devel] (updated) [PATCH] Warn when using verb levels >=7 without debug
2013-03-20 16:42 ` Arne Schwabe
@ 2013-03-20 18:22 ` Josh Cepek
2013-03-20 19:15 ` Arne Schwabe
2013-03-20 20:59 ` [Openvpn-devel] [PATCH applied] " Gert Doering
0 siblings, 2 replies; 5+ messages in thread
From: Josh Cepek @ 2013-03-20 18:22 UTC (permalink / raw)
To: openvpn-devel
[-- Attachment #1: Type: text/plain, Size: 313 bytes --]
On 3/20/2013 11:42, Arne Schwabe wrote:
> ACK. But I would change "debug verb" to "debug verbosity" and I think
> there should be no comma before "but"
This text change makes sense: I've adjusted it to read "NOTE: debug
verbosity..." and saved another byte removing the comma.
Updated patch attached.
--
Josh
[-- Attachment #2: 0001-Warn-when-using-verb-levels-7-without-debug.patch --]
[-- Type: text/plain, Size: 1407 bytes --]
From d41a0237220f2fea6647a508a2ab07263e0f160b Mon Sep 17 00:00:00 2001
From: Josh Cepek <josh.cepek@...1085...>
Date: Tue, 19 Mar 2013 22:52:12 -0500
Subject: [PATCH] Warn when using verb levels >=7 without debug
This patch adds a log warning when using --verb levels at 7 or higher
when running on builds lacking debug support. Since official builds are
now built with enable_debug=no, this warning will help developers
identify why expected debug messages may not be present in log output.
The test and message output code is omitted when built with
enable_debug=yes or enable_small=yes.
Signed-off-by: Josh Cepek <josh.cepek@...1085...>
---
src/openvpn/options.c | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/src/openvpn/options.c b/src/openvpn/options.c
index 2eb4f91..ec39212 100644
--- a/src/openvpn/options.c
+++ b/src/openvpn/options.c
@@ -4672,6 +4672,12 @@ add_option (struct options *options,
{
VERIFY_PERMISSION (OPT_P_MESSAGES);
options->verbosity = positive_atoi (p[1]);
+#if !defined(ENABLE_DEBUG) && !defined(ENABLE_SMALL)
+ /* Warn when a debug verbosity is supplied when built without debug support */
+ if (options->verbosity >= 7)
+ msg (M_WARN, "NOTE: debug verbosity (--verb %d) is enabled but this build lacks debug support.",
+ options->verbosity);
+#endif
}
else if (streq (p[0], "mute") && p[1])
{
--
1.7.12.4
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [Openvpn-devel] (updated) [PATCH] Warn when using verb levels >=7 without debug
2013-03-20 18:22 ` [Openvpn-devel] (updated) " Josh Cepek
@ 2013-03-20 19:15 ` Arne Schwabe
2013-03-20 20:59 ` [Openvpn-devel] [PATCH applied] " Gert Doering
1 sibling, 0 replies; 5+ messages in thread
From: Arne Schwabe @ 2013-03-20 19:15 UTC (permalink / raw)
To: Josh Cepek <josh.cepek@; +Cc: openvpn-devel
[-- Attachment #1: Type: text/plain, Size: 399 bytes --]
Am 20.03.13 19:22, schrieb Josh Cepek:
> On 3/20/2013 11:42, Arne Schwabe wrote:
>
>> ACK. But I would change "debug verb" to "debug verbosity" and I think
>> there should be no comma before "but"
> This text change makes sense: I've adjusted it to read "NOTE: debug
> verbosity..." and saved another byte removing the comma.
>
> Updated patch attached.
>
>
ACK to that patch.
Arne
[-- Attachment #2: S/MIME Kryptografische Unterschrift --]
[-- Type: application/pkcs7-signature, Size: 5528 bytes --]
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Openvpn-devel] [PATCH applied] Re: (updated) [PATCH] Warn when using verb levels >=7 without debug
2013-03-20 18:22 ` [Openvpn-devel] (updated) " Josh Cepek
2013-03-20 19:15 ` Arne Schwabe
@ 2013-03-20 20:59 ` Gert Doering
1 sibling, 0 replies; 5+ messages in thread
From: Gert Doering @ 2013-03-20 20:59 UTC (permalink / raw)
To: Josh Cepek <josh.cepek@; +Cc: openvpn-devel
Your patch has been applied to the master and release/2.3 branch.
commit 58fbb8046b203ca23708c1765ee84330d8809266 (master)
commit 152ca3e49f14b8fe8e7e52daf3cf11851fb98acd (release/2.3)
Author: Josh Cepek
Date: Wed Mar 20 13:22:25 2013 -0500
(updated) [PATCH] Warn when using verb levels >=7 without debug
Signed-off-by: Josh Cepek <josh.cepek@...1085...>
Acked-by: Arne Schwabe <arne@...1227...>
Message-Id: <kicup2$gfv$1@...1062...>
URL: http://article.gmane.org/gmane.network.openvpn.devel/7425
Signed-off-by: Gert Doering <gert@...1296...>
--
kind regards,
Gert Doering
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2013-03-20 20:59 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-03-20 16:32 [Openvpn-devel] [PATCH] Warn when using verb levels >=7 without debug Josh Cepek
2013-03-20 16:42 ` Arne Schwabe
2013-03-20 18:22 ` [Openvpn-devel] (updated) " Josh Cepek
2013-03-20 19:15 ` Arne Schwabe
2013-03-20 20:59 ` [Openvpn-devel] [PATCH applied] " Gert Doering
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.