summaryrefslogtreecommitdiff
Diffstat
-rwxr-xr-xAndroid.mk4
-rwxr-xr-xjni/src/common.c159
-rwxr-xr-xjni/src/discovery.c3
-rwxr-xr-xjni/src/pppoe.c2
-rwxr-xr-xjni/src/pppoe_cli.c11
5 files changed, 176 insertions, 3 deletions
diff --git a/jni/src/pppoe_cli.c b/jni/src/pppoe_cli.c
index 9c23af5..e453416 100755
--- a/jni/src/pppoe_cli.c
+++ b/jni/src/pppoe_cli.c
@@ -35,10 +35,19 @@ int main(int argc, char *argv[])
struct netwrapper_ctrl * ctrl;
if (argc < 2 || (0 != strcmp( "connect", argv[1]) &&
- 0 != strcmp( "disconnect", argv[1]) )) {
+ 0 != strcmp( "disconnect", argv[1] ) &&
+ 0 != strcmp( "terminate", argv[1] ))) {
usage();
return -2;
}
+
+ if (0 == strcmp( "terminate", argv[1] )) {
+ for ( i = 0; i < 3; i++ ) {
+ sendSavedPADT(_ROOT_PATH "/etc/ppp/padt_bin");
+ sleep(1);
+ }
+ return 0;
+ }
ctrl = netwrapper_ctrl_open(_ROOT_PATH "/etc/ppp/pppcli", PPPOE_WRAPPER_SERVER_PATH);
if (ctrl == NULL) {