fix date formatting in mail messages (thanks Marcus for reporting)
[openwrt.git] / package / ppp / patches / 106-debian_pppoatm_fix_mtu.patch
1 diff -ruNp ppp-2.4.3.orig/pppd/plugins/pppoatm/pppoatm.c ppp-2.4.3/pppd/plugins/pppoatm/pppoatm.c
2 --- ppp-2.4.3.orig/pppd/plugins/pppoatm/pppoatm.c 2005-05-04 02:00:28.000000000 +0200
3 +++ ppp-2.4.3/pppd/plugins/pppoatm/pppoatm.c 2005-05-04 01:59:11.000000000 +0200
4 @@ -183,8 +183,11 @@ static void send_config_pppoa(int mtu,
5 int sock;
6 struct ifreq ifr;
7
8 - if (mtu > pppoatm_max_mtu)
9 - error("Couldn't increase MTU to %d", mtu);
10 + if (pppoatm_max_mtu && mtu > pppoatm_max_mtu) {
11 + warn("Couldn't increase MTU to %d. Using %d",
12 + mtu, pppoatm_max_mtu);
13 + mtu = pppoatm_max_mtu;
14 + }
15
16 sock = socket(AF_INET, SOCK_DGRAM, 0);
17 if (sock < 0)
18 @@ -202,8 +205,11 @@ static void recv_config_pppoa(int mru,
19 int pcomp,
20 int accomp)
21 {
22 - if (mru > pppoatm_max_mru)
23 - error("Couldn't increase MRU to %d", mru);
24 + if (pppoatm_max_mru && mru > pppoatm_max_mru) {
25 + warn("Couldn't increase MRU to %d. Using %d",
26 + mru, pppoatm_max_mru);
27 + mru = pppoatm_max_mru;
28 + }
29 }
30
31 void plugin_init(void)
This page took 0.043224 seconds and 5 git commands to generate.