diff options
author | David S. Miller <davem@davemloft.net> | 2014-07-22 11:44:59 +0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2014-07-22 11:44:59 +0400 |
commit | 8fd90bb889635fa1e7f80a3950948cc2e74c1446 (patch) | |
tree | 1490343b5ad9f88b9333e53fa9457c00cbf6c2d1 /drivers/net/ppp | |
parent | 1bb4238b17b5de6cdc120970a9d00dd8a44f40df (diff) | |
parent | 15ba2236f3556fc01b9ca91394465152b5ea74b6 (diff) | |
download | linux-8fd90bb889635fa1e7f80a3950948cc2e74c1446.tar.xz |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net
Conflicts:
drivers/infiniband/hw/cxgb4/device.c
The cxgb4 conflict was simply overlapping changes.
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ppp')
-rw-r--r-- | drivers/net/ppp/ppp_generic.c | 22 |
1 files changed, 16 insertions, 6 deletions
diff --git a/drivers/net/ppp/ppp_generic.c b/drivers/net/ppp/ppp_generic.c index 2031ce4051dc..765248b42a0a 100644 --- a/drivers/net/ppp/ppp_generic.c +++ b/drivers/net/ppp/ppp_generic.c @@ -761,10 +761,15 @@ static long ppp_ioctl(struct file *file, unsigned int cmd, unsigned long arg) }; ppp_lock(ppp); - if (ppp->pass_filter) + if (ppp->pass_filter) { sk_unattached_filter_destroy(ppp->pass_filter); - err = sk_unattached_filter_create(&ppp->pass_filter, - &fprog); + ppp->pass_filter = NULL; + } + if (fprog.filter != NULL) + err = sk_unattached_filter_create(&ppp->pass_filter, + &fprog); + else + err = 0; kfree(code); ppp_unlock(ppp); } @@ -782,10 +787,15 @@ static long ppp_ioctl(struct file *file, unsigned int cmd, unsigned long arg) }; ppp_lock(ppp); - if (ppp->active_filter) + if (ppp->active_filter) { sk_unattached_filter_destroy(ppp->active_filter); - err = sk_unattached_filter_create(&ppp->active_filter, - &fprog); + ppp->active_filter = NULL; + } + if (fprog.filter != NULL) + err = sk_unattached_filter_create(&ppp->active_filter, + &fprog); + else + err = 0; kfree(code); ppp_unlock(ppp); } |