From: Bernhard Tittelbach Date: Sat, 5 Oct 2013 00:35:21 +0000 (+0000) Subject: cleanup code X-Git-Url: https://git.realraum.at/?a=commitdiff_plain;h=52e539857287337cd45591c4a1a0023600bcbb92;p=svn42.git cleanup code --- diff --git a/go/r3-netstatus/main.go b/go/r3-netstatus/main.go index afebd58..0a4b0c9 100644 --- a/go/r3-netstatus/main.go +++ b/go/r3-netstatus/main.go @@ -117,6 +117,12 @@ func EventToXMPP(ps *pubsub.PubSub, xmpp_presence_events_chan_ chan <- interface } } +func ParseZMQr3Event(lines [][]byte, ps *pubsub.PubSub) { + evnt, pubsubcat, err := r3events.UnmarshalByteByte2Event(lines) + if err != nil { return } + ps.Pub(evnt, pubsubcat) +} + func main() { if enable_syslog_ { LogEnableSyslog(); r3xmppbot.LogEnableSyslog() } if enable_debug_ { LogEnableDebuglog(); r3xmppbot.LogEnableDebuglog() } diff --git a/go/r3-netstatus/sockettoevent.go b/go/r3-netstatus/sockettoevent.go deleted file mode 100644 index 7165ac6..0000000 --- a/go/r3-netstatus/sockettoevent.go +++ /dev/null @@ -1,14 +0,0 @@ -// (c) Bernhard Tittelbach, 2013 - -package main - -import ( - pubsub "github.com/tuxychandru/pubsub" - r3events "svn.spreadspace.org/realraum/go.svn/r3-eventbroker_zmq/r3events" - ) - -func ParseZMQr3Event(lines [][]byte, ps *pubsub.PubSub) { - evnt, pubsubcat, err := r3events.UnmarshalByteByte2Event(lines) - if err != nil { return } - ps.Pub(evnt, pubsubcat) -}