2017-02-25 05:56:40 +00:00
|
|
|
package genericlistener
|
|
|
|
|
|
|
|
import (
|
|
|
|
"log"
|
|
|
|
"os"
|
2017-03-13 21:46:11 +00:00
|
|
|
"runtime"
|
2017-02-25 05:56:40 +00:00
|
|
|
)
|
|
|
|
|
|
|
|
var (
|
2017-03-13 21:46:11 +00:00
|
|
|
loginfo *log.Logger
|
|
|
|
logdebug *log.Logger
|
|
|
|
logFlags = log.Ldate | log.Lmicroseconds | log.Lshortfile
|
|
|
|
connectionID int64
|
2017-02-25 05:56:40 +00:00
|
|
|
)
|
|
|
|
|
|
|
|
func init() {
|
2017-03-02 03:02:20 +00:00
|
|
|
loginfo = log.New(os.Stdout, "INFO: genericlistener: ", logFlags)
|
|
|
|
logdebug = log.New(os.Stdout, "DEBUG: genericlistener:", logFlags)
|
2017-03-13 21:46:11 +00:00
|
|
|
pc, _, _, _ := runtime.Caller(0)
|
|
|
|
loginfo.Println(runtime.FuncForPC(pc).Name())
|
|
|
|
|
|
|
|
connectionID = 0
|
2017-02-25 05:56:40 +00:00
|
|
|
}
|