Module Name:    src
Committed By:   pgoyette
Date:           Mon Mar 25 10:04:48 UTC 2019

Modified Files:
        src/sys/net: if_tun.c

Log Message:
in tundetach(), error is only used #ifdef _MODULE so wrap its declaration.


To generate a diff of this commit:
cvs rdiff -u -r1.154 -r1.155 src/sys/net/if_tun.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/net/if_tun.c
diff -u src/sys/net/if_tun.c:1.154 src/sys/net/if_tun.c:1.155
--- src/sys/net/if_tun.c:1.154	Mon Mar 25 09:07:24 2019
+++ src/sys/net/if_tun.c	Mon Mar 25 10:04:48 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: if_tun.c,v 1.154 2019/03/25 09:07:24 pgoyette Exp $	*/
+/*	$NetBSD: if_tun.c,v 1.155 2019/03/25 10:04:48 pgoyette Exp $	*/
 
 /*
  * Copyright (c) 1988, Julian Onions <j...@cs.nott.ac.uk>
@@ -19,7 +19,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: if_tun.c,v 1.154 2019/03/25 09:07:24 pgoyette Exp $");
+__KERNEL_RCSID(0, "$NetBSD: if_tun.c,v 1.155 2019/03/25 10:04:48 pgoyette Exp $");
 
 #ifdef _KERNEL_OPT
 #include "opt_inet.h"
@@ -142,7 +142,9 @@ tuninit(void)
 static int
 tundetach(void)
 {
-	int error = 0;
+#ifdef _MODULE
+	int error;
+#endif
 
 	if_clone_detach(&tun_cloner);
 #ifdef _MODULE

Reply via email to