int pppoe_down_main(int argc, char **argv) { if (argc < 2) return 0; TRACE_PT("num=%s\n", argv[1]); if (atoi(argv[1]) != 0) return 0; if ((nvram_get_int("ppp_demand")) && (nvram_match("action_service", ""))) { stop_singe_pppoe(0); start_pppoe(0); stop_dnsmasq(); dns_to_resolv(); start_dnsmasq(); } return 0; }
// by tallest 0407 int disconnected_pppoe_main(int argc, char **argv) { int pppoe_num = atoi(argv[1]); char ppp_demand[2][20] = { "ppp_demand", "ppp_demand_1" }; if (nvram_match(ppp_demand[pppoe_num], "1") && nvram_match("action_service", "")) { cprintf("tallest:=====( kill pppoe %d )=====\n", pppoe_num); stop_single_pppoe(pppoe_num); start_pppoe(pppoe_num); dns_to_resolv(); stop_dnsmasq(); start_dnsmasq(); return 0; } cprintf("tallest:=====( PPPOE Dial On Demand Error!! )=====\n"); return 0; }