minor fixes

This commit is contained in:
cx uname 2012-11-01 15:59:29 +04:00
parent b8d9ec9e39
commit 86a61cf2bf
1 changed files with 5 additions and 3 deletions

View File

@ -1,8 +1,8 @@
package main package main
import ( import (
"github.com/cxindex/xmpp"
"fmt" "fmt"
"github.com/cxindex/xmpp"
"io/ioutil" "io/ioutil"
"log" "log"
"os/exec" "os/exec"
@ -71,8 +71,7 @@ start:
case next = <-cs: case next = <-cs:
log.Println(next.Value) log.Println(next.Value)
case <-time.After(65 * time.Second): case <-time.After(65 * time.Second):
log.Println("closed after 65 seconds of inactivity") log.Println(Conn.Close(), "\n\t", "closed after 65 seconds of inactivity")
Conn.Close()
goto start goto start
} }
switch t := next.Value.(type) { switch t := next.Value.(type) {
@ -95,6 +94,9 @@ start:
log.Println("da fuq?") log.Println("da fuq?")
} }
} }
log.Println(Conn.Close(), "\n\t", "wtf am I doing here?")
time.Sleep(5 * time.Second)
goto start
} }
func SelfHandler(Conn *xmpp.Conn, Msg *xmpp.ClientMessage) { func SelfHandler(Conn *xmpp.Conn, Msg *xmpp.ClientMessage) {