diff --git a/webif/html/diag/mux.jim b/webif/html/diag/mux.jim
index ce1a72ad..6f9f8662 100755
--- a/webif/html/diag/mux.jim
+++ b/webif/html/diag/mux.jim
@@ -15,8 +15,7 @@ if {[catch {set db [sqlite3.open /var/lib/humaxtv/channel.db]} msg]} {
pkg loadmuxdb
proc f2c {frequency} {
- set ch int($((($frequency / 1000) - 303.25) / 8))
- return [expr {int($ch)}]
+ return $(int((($frequency / 1000) - 303.25) / 8))
}
proc svc2mux {svcid mux} {
diff --git a/webif/html/sched/visual/index.jim b/webif/html/sched/visual/index.jim
index 12607538..14e1bf4a 100755
--- a/webif/html/sched/visual/index.jim
+++ b/webif/html/sched/visual/index.jim
@@ -23,7 +23,7 @@ lmap i \
#set svcmap [lreverse $hmap]
proc lsum {l} {
- expr [join $l +] + 0
+ expr [join [linsert $l 0 0] +]
}
proc pop_event {} {
diff --git a/webif/html/xepg/index.jim b/webif/html/xepg/index.jim
index 229cb3df..9e334623 100755
--- a/webif/html/xepg/index.jim
+++ b/webif/html/xepg/index.jim
@@ -201,10 +201,11 @@ puts ""
######################################################################
# Events
+if {[catch {set stt2 [expr {$stt + 0}]}]} { set stt2 0 }
puts "
"