diff options
author | Vladislav Grishenko <themiron@mail.ru> | 2014-09-01 15:05:35 +0600 |
---|---|---|
committer | Dmitry Kozlov <xeb@mail.ru> | 2014-09-13 11:01:31 +0400 |
commit | e950491e32510700e73df5d1de0ecd5d762afe4d (patch) | |
tree | 3afdc75fb44f9581959b7bd63c6174f12bc6cffe | |
parent | 9d89c061153285971ebf4cc79f68a8d4dd598c8a (diff) | |
download | accel-ppp-e950491e32510700e73df5d1de0ecd5d762afe4d.tar.gz accel-ppp-e950491e32510700e73df5d1de0ecd5d762afe4d.zip |
ppp: update channel MRU as pppd does
-rw-r--r-- | accel-pppd/ppp/lcp_opt_mru.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/accel-pppd/ppp/lcp_opt_mru.c b/accel-pppd/ppp/lcp_opt_mru.c index 10dc54e..1cd04f8 100644 --- a/accel-pppd/ppp/lcp_opt_mru.c +++ b/accel-pppd/ppp/lcp_opt_mru.c @@ -123,6 +123,10 @@ static int mru_recv_conf_ack(struct ppp_lcp_t *lcp, struct lcp_option_t *opt, ui strcpy(ifr.ifr_name, lcp->ppp->ses.ifname); + if (ioctl(lcp->ppp->chan_fd, PPPIOCSMRU, &mru_opt->mru) && + errno != EIO && errno != ENOTTY) + log_ppp_error("lcp:mru: failed to set channel MRU: %s\n", strerror(errno)); + if (ioctl(lcp->ppp->unit_fd, PPPIOCSMRU, &mru_opt->mru)) log_ppp_error("lcp:mru: failed to set MRU: %s\n", strerror(errno)); |