Skip to contentSkip to conversation

2.6.7-bk7 ppp_generic.c get_filter made conditional

PATCH New Paul Fulghum 1 participant 1 message Jun 24, 2004 Network drivers

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 2.6.7-bk7 ppp_generic.c get_filter made conditional

Add #ifdef CONFIG_PPP_FILTER around get_filter implementation which is only used when this option is enabled. This prevents compiler warning (unused function) when CONFIG_PPP_FILTER is not defined.

--
Paul Fulghum
[email protected]

drivers/net/ppp_generic.c +2 -0
@@ -494,6 +494,7 @@
 	return mask;
 }
 
+#ifdef CONFIG_PPP_FILTER
 static int get_filter(void __user *arg, struct sock_filter **p)
 {
 	struct sock_fprog uprog;
@@ -530,6 +531,7 @@
 	*p = code;
 	return uprog.len;
 }
+#endif /* CONFIG_PPP_FILTER */
 
 static int ppp_ioctl(struct inode *inode, struct file *file,
 		     unsigned int cmd, unsigned long arg)