summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorOpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com>2020-06-11 04:45:52 -0400
committerGitHub <noreply@github.com>2020-06-11 04:45:52 -0400
commit7b85d5c6d272da17bcdb9fb266859c3e5ec8fd09 (patch)
tree41775c4859ebc015617db3958d34c16d99d96f1f
parentb2200dbe056ac409461033f646cdd25bcccea521 (diff)
parent86ffa552d2af02bdcc06e8a0e93095b7d0110395 (diff)
downloadpodman-7b85d5c6d272da17bcdb9fb266859c3e5ec8fd09.tar.gz
podman-7b85d5c6d272da17bcdb9fb266859c3e5ec8fd09.tar.bz2
podman-7b85d5c6d272da17bcdb9fb266859c3e5ec8fd09.zip
Merge pull request #6561 from CUB-OIT-PE/fix-truncated-logs
Fixed bug where 'podman log <container>' would truncate some lines.
-rw-r--r--libpod/container_log.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/libpod/container_log.go b/libpod/container_log.go
index bfa303e84..c3a84d048 100644
--- a/libpod/container_log.go
+++ b/libpod/container_log.go
@@ -19,7 +19,7 @@ func (r *Runtime) Log(containers []*Container, options *logs.LogOptions, logChan
return nil
}
-// ReadLog reads a containers log based on the input options and returns loglines over a channel
+// ReadLog reads a containers log based on the input options and returns loglines over a channel.
func (c *Container) ReadLog(options *logs.LogOptions, logChannel chan *logs.LogLine) error {
// TODO Skip sending logs until journald logs can be read
// TODO make this not a magic string
@@ -61,7 +61,7 @@ func (c *Container) readFromLogFile(options *logs.LogOptions, logChannel chan *l
partial += nll.Msg
continue
} else if !nll.Partial() && len(partial) > 1 {
- nll.Msg = partial
+ nll.Msg = partial + nll.Msg
partial = ""
}
nll.CID = c.ID()