From c1d1f2be41ab84ce25f1f0f4d518e112cf7fd7c4 Mon Sep 17 00:00:00 2001 From: Erik Troan Date: Fri, 6 Feb 1998 06:38:30 +0000 Subject: didn't work for cloned devices --- src/usernetctl.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/usernetctl.c b/src/usernetctl.c index 81401dae..bad10c96 100644 --- a/src/usernetctl.c +++ b/src/usernetctl.c @@ -107,6 +107,7 @@ int main(int argc, char ** argv) { char * chptr; char * cmd; int report = 0; + char tmp; if (argc != 3) usage(); @@ -154,10 +155,14 @@ int main(int argc, char ** argv) { dash = strrchr(ifaceConfig, '-'); if (*(dash-1) != 'g') { /* This was a clone configuration; ask the parent config */ + tmp = *dash; *dash = '\0'; - if (userCtl(ifaceConfig) == FOUND_TRUE) + if (userCtl(ifaceConfig) == FOUND_TRUE) { /* exit the switch; users are allowed to control */ + *dash = tmp; break; + } + *dash = tmp; } /* else fall through */ case FOUND_FALSE: -- cgit v1.2.1