Patchwork [2/2] extensions: libxt_dccp/libxt_sctp: enable debug tracing by DEBUG define

login
register
mail settings
Submitter Alexey Perevalov
Date July 4, 2013, 7:26 a.m.
Message ID <1372922778-12997-3-git-send-email-a.perevalov@samsung.com>
Download mbox | patch
Permalink /patch/256812/
State Changes Requested
Headers show

Comments

Alexey Perevalov - July 4, 2013, 7:26 a.m.
Signed-off-by: Alexey Perevalov <a.perevalov@samsung.com>
---
 extensions/libxt_dccp.c |    4 ++--
 extensions/libxt_sctp.c |    4 ++--
 2 files changed, 4 insertions(+), 4 deletions(-)
Pablo Neira - July 8, 2013, 2:55 a.m.
On Thu, Jul 04, 2013 at 11:26:18AM +0400, Alexey Perevalov wrote:
> Signed-off-by: Alexey Perevalov <a.perevalov@samsung.com>
> ---
>  extensions/libxt_dccp.c |    4 ++--
>  extensions/libxt_sctp.c |    4 ++--
>  2 files changed, 4 insertions(+), 4 deletions(-)
> 
> diff --git a/extensions/libxt_dccp.c b/extensions/libxt_dccp.c
> index a35cabb..06cd23d 100644
> --- a/extensions/libxt_dccp.c
> +++ b/extensions/libxt_dccp.c
> @@ -16,11 +16,11 @@
>  #include <linux/netfilter/x_tables.h>
>  #include <linux/netfilter/xt_dccp.h>
>  
> -#if 0
> +#ifdef DEBUG
>  #define DEBUGP(format, first...) printf(format, ##first)
>  #define static
>  #else
> -#define DEBUGP(format, fist...) 
> +#define DEBUGP(format, fist...)
>  #endif

I don't find any client of this code for libxt_dccp, better delete it
in that case.

>  enum {
> diff --git a/extensions/libxt_sctp.c b/extensions/libxt_sctp.c
> index 56a4cdf..f5959cb 100644
> --- a/extensions/libxt_sctp.c
> +++ b/extensions/libxt_sctp.c
> @@ -20,11 +20,11 @@
>  
>  #include <linux/netfilter/xt_sctp.h>
>  
> -#if 0
> +#if DEBUG
>  #define DEBUGP(format, first...) printf(format, ##first)
>  #define static
>  #else
> -#define DEBUGP(format, fist...) 
> +#define DEBUGP(format, fist...)
>  #endif
>  
>  static void
> -- 
> 1.7.9.5
> 
> --
> To unsubscribe from this list: send the line "unsubscribe netfilter-devel" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
--
To unsubscribe from this list: send the line "unsubscribe netfilter-devel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Patch

diff --git a/extensions/libxt_dccp.c b/extensions/libxt_dccp.c
index a35cabb..06cd23d 100644
--- a/extensions/libxt_dccp.c
+++ b/extensions/libxt_dccp.c
@@ -16,11 +16,11 @@ 
 #include <linux/netfilter/x_tables.h>
 #include <linux/netfilter/xt_dccp.h>
 
-#if 0
+#ifdef DEBUG
 #define DEBUGP(format, first...) printf(format, ##first)
 #define static
 #else
-#define DEBUGP(format, fist...) 
+#define DEBUGP(format, fist...)
 #endif
 
 enum {
diff --git a/extensions/libxt_sctp.c b/extensions/libxt_sctp.c
index 56a4cdf..f5959cb 100644
--- a/extensions/libxt_sctp.c
+++ b/extensions/libxt_sctp.c
@@ -20,11 +20,11 @@ 
 
 #include <linux/netfilter/xt_sctp.h>
 
-#if 0
+#if DEBUG
 #define DEBUGP(format, first...) printf(format, ##first)
 #define static
 #else
-#define DEBUGP(format, fist...) 
+#define DEBUGP(format, fist...)
 #endif
 
 static void