summaryrefslogtreecommitdiff
blob: 44011f62ab87e500271c67fe60b95af5eebbc399 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
diff --git a/opt/teamviewer9/tv_bin/script/tvw_extra b/opt/teamviewer9/tv_bin/script/tvw_extra
index ae90b2d..f7ce7c1 100644
--- a/opt/teamviewer9/tv_bin/script/tvw_extra
+++ b/opt/teamviewer9/tv_bin/script/tvw_extra
@@ -31,20 +31,9 @@ function PrintInfo()
 {
   PrintVersion
   echo
-  PrintDaemonStatus
-  echo
   PrintTeamViewerID
 }
 
-function PrintDaemonStatus()
-{
-  local cmd="$(daemonCtl 'status')"
-  local txt="$(eval "$cmd")"
-  [ $? = 0 ] || txt='n/a (error)'
-  
-  ABecho "teamviewerd status" "$txt"
-}
-
 function PrintTeamViewerID()
 {
   local config="$TV_BASE_DIR/config/global.conf"
@@ -55,18 +44,18 @@ function PrintTeamViewerID()
   if [ -n "$tvid" ]; then
     ABecho "TeamViewer ID:" "$tvid"
   else
-    echo "TeamViewer ID: not found"
-    echo "Try restarting the TeamViewer daemon (e.g. teamviewer --daemon restart)"
+    echo "Try restarting the TeamViewer daemon."
   fi
 }
 
 function SetPasswd()
 {
+  echo "Stop your teamviewer daemon first, then press enter."
+  read
+
   local pwd="$1"
   [ -n "$pwd" ] || die 'no password specified'
 
-  Run_Daemon 'stop' > /dev/null
-  
   $TV_BIN_DIR/teamviewerd --passwd "$pwd"
   case $? in
     0  ) echo 'ok'	;;
@@ -76,18 +65,18 @@ function SetPasswd()
     *  ) echo 'unknown response'	;;
    esac
   
-  Run_Daemon 'start' || die 'failed to restart the daemon'
-  echo
+  echo "You may start your teamviewer daemon again."
 }
 
 function ExportLicense()
 {
+  echo "Stop your teamviewer daemon first, then press enter."
+  read
+
   local license="$1"
   local path='/tmp/tv_global.conf'
 
   [ -n "$license" ] || die 'no license specified'
-
-  Run_Daemon 'stop' > /dev/null
   
   $TV_BIN_DIR/teamviewerd --export-license "$license" "$path"
   case $? in
@@ -96,8 +85,7 @@ function ExportLicense()
     *  ) echo 'unknown response'	;;
    esac
   
-  Run_Daemon 'start' || die 'failed to restart the daemon'
-  echo
+  echo "You may start your teamviewer daemon again."
 }
 
 function CreateZipLog()
diff --git a/opt/teamviewer9/tv_bin/script/tvw_main b/opt/teamviewer9/tv_bin/script/tvw_main
index cb4553a..7fe6571 100644
--- a/opt/teamviewer9/tv_bin/script/tvw_main
+++ b/opt/teamviewer9/tv_bin/script/tvw_main
@@ -4,7 +4,6 @@ source "$TV_SCRIPT_DIR/tvw_aux"
 source "$TV_SCRIPT_DIR/tvw_config"
 source "$TV_SCRIPT_DIR/tvw_exec"
 source "$TV_SCRIPT_DIR/tvw_extra"
-source "$TV_SCRIPT_DIR/tvw_daemon"
 source "$TV_SCRIPT_DIR/tvw_profile"
 
 
@@ -19,7 +18,6 @@ function Main()
     --help )		PrintHelp			;;
     --version )		PrintVersion			;;
     --info )		PrintInfo			;;
-    --daemon )		Run_Daemon $opt			;;
     --winecfg )		shift; Run_WineCfg "$@"		;;
     --regedit )		shift; Run_RegEdit "$@"		;;
     --kill )		Run_KillTeamViewer		;;
@@ -149,16 +147,3 @@ function Run_RegEdit()
   Init
   wine regedit "$@"
 }
-
-function Run_Daemon()
-{
-  local opt="$1"
-
-  case "$opt" in
-    ( disable )				removeDaemon	|| rootSuggest	;;
-    ( enable  )				installDaemon	|| rootSuggest	;;
-    ( start | stop | restart )		cmdDaemon $opt	|| rootSuggest	;;
-    ( status )				cmdDaemon $opt			;;
-    ( * )				echo "unknown option '$opt'"	;;
-  esac
-}