]> git.entuzijast.net Git - imunes.git/commitdiff
indentation fixes
authorJosip Rodin <joy@numa-ubuntu-vm.(none)>
Sun, 13 Sep 2009 22:48:42 +0000 (00:48 +0200)
committerJosip Rodin <joy@numa-ubuntu-vm.(none)>
Sun, 13 Sep 2009 22:48:42 +0000 (00:48 +0200)
linux/exec.tcl

index 1d205bc7d637b591e4dff2cd7f9492747bfb9543..61dc5d10b77ac3dc2593e1bc33f97a648cffcb9c 100755 (executable)
@@ -112,37 +112,38 @@ proc setOperMode { mode } {
 
     # Verify that links to external interfaces are properly configured
     if { $mode == "exec" } {
-       # popis interfacea (BSD ifconfig -l)
-       set extifcs_p [open "| ip link show"]
-       set extifcs_s [read $extifcs_p]
-       if { [catch {close $extifcs_p} err] } {
-           puts "ip link show failed: $err"
-       }
-       set extifcs_o [split $extifcs_s \n]
-       set extifcs {}
-       foreach iplink_line $extifcs_o {
-           if { [ regexp -- {^\d+: ([^:]+): } $iplink_line -> extif ] == 0 } {
-               continue
-           }
-               # izbaci loopback interface iz popisa (BSD lo0)
-               if { $extif == "lo" } {
-                       continue
+               # popis interfacea (BSD ifconfig -l)
+               set extifcs_p [open "| ip link show"]
+               set extifcs_s [read $extifcs_p]
+               if { [catch {close $extifcs_p} err] } {
+                   puts "ip link show failed: $err"
                }
-               #puts "external interface found: $extif"
-           lappend extifcs $extif
-       }
-       foreach node $node_list {
-           if { [nodeType $node] == "rj45" } {
-               set i [lsearch $extifcs [getNodeName $node]]
-               if { $i < 0 } {
-                   after idle {.dialog1.msg configure -wraplength 4i}
-                   tk_dialog .dialog1 "IMUNES error" \
-                       "Error: external interface \"[getNodeName $node]\" non-existant" \
-                   info 0 Dismiss
-                   return
+               set extifcs_o [split $extifcs_s \n]
+               set extifcs {}
+               foreach iplink_line $extifcs_o {
+                   if { [ regexp -- {^\d+: ([^:]+): } $iplink_line -> extif ] == 0 } {
+                       continue
+                   }
+                       # izbaci loopback interface iz popisa (BSD lo0)
+                       if { $extif == "lo" } {
+                               continue
+                       }
+                       #puts "external interface found: $extif"
+                   lappend extifcs $extif
+               }
+               foreach node $node_list {
+                   if { [nodeType $node] != "rj45" } {
+                       continue
+                   }
+                       set i [lsearch $extifcs [getNodeName $node]]
+                       if { $i < 0 } {
+                           after idle {.dialog1.msg configure -wraplength 4i}
+                           tk_dialog .dialog1 "IMUNES error" \
+                               "Error: external interface \"[getNodeName $node]\" non-existant" \
+                           info 0 Dismiss
+                           return
+                   }
                }
-           }
-       }
     }
 
     foreach b {link router hub lanswitch host pc rj45} {