Skip to content

Commit

Permalink
Merge pull request #8 from vcostet/fix-udp-receiver-loop
Browse files Browse the repository at this point in the history
In UDP mode, messages are truncated
  • Loading branch information
hartfordfive committed Aug 29, 2017
2 parents 6a21398 + 628cc81 commit 123c3af
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion protolog/loglistener.go
Expand Up @@ -99,9 +99,9 @@ func (ll *LogListener) startUDP(proto string, address string) {
defer l.Close()

logp.Info("Now listening for logs via %s on %s", ll.config.Protocol, address)
buffer := make([]byte, ll.config.MaxMsgSize)

for {
buffer := make([]byte, ll.config.MaxMsgSize)
length, _, err := l.ReadFrom(buffer)
if err != nil {
logp.Err("Error reading from buffer: %v", err.Error())
Expand Down

0 comments on commit 123c3af

Please sign in to comment.