From 52e539857287337cd45591c4a1a0023600bcbb92 Mon Sep 17 00:00:00 2001 From: Bernhard Tittelbach Date: Sat, 5 Oct 2013 00:35:21 +0000 Subject: [PATCH] cleanup code --- go/r3-netstatus/main.go | 6 ++++++ go/r3-netstatus/sockettoevent.go | 14 -------------- 2 files changed, 6 insertions(+), 14 deletions(-) delete mode 100644 go/r3-netstatus/sockettoevent.go 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) -} -- 1.7.10.4