aboutsummaryrefslogtreecommitdiff
path: root/pkg/api
diff options
context:
space:
mode:
authorcdoern <cdoern@redhat.com>2021-08-09 10:07:46 -0400
committerMatthew Heon <mheon@redhat.com>2021-08-30 13:34:56 -0400
commitaa754c7e2193e6f82a8c14f482bc58a7a5b07550 (patch)
treef0c3c05fda3f98eb8e7e22c93dd685d077997b9c /pkg/api
parentf363b805c59ed4d25d89f08e3a099e5c7028eb2f (diff)
downloadpodman-aa754c7e2193e6f82a8c14f482bc58a7a5b07550.tar.gz
podman-aa754c7e2193e6f82a8c14f482bc58a7a5b07550.tar.bz2
podman-aa754c7e2193e6f82a8c14f482bc58a7a5b07550.zip
logFile until flag issue
we were adding a negative duration in podman events, causing inputs like -5s to be correct and 5s to be incorrect. fixes #11158 Signed-off-by: cdoern <cdoern@redhat.com>
Diffstat (limited to 'pkg/api')
-rw-r--r--pkg/api/handlers/compat/containers_logs.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/pkg/api/handlers/compat/containers_logs.go b/pkg/api/handlers/compat/containers_logs.go
index 656e2c627..50cdb1e65 100644
--- a/pkg/api/handlers/compat/containers_logs.go
+++ b/pkg/api/handlers/compat/containers_logs.go
@@ -63,7 +63,7 @@ func LogsFromContainer(w http.ResponseWriter, r *http.Request) {
var since time.Time
if _, found := r.URL.Query()["since"]; found {
- since, err = util.ParseInputTime(query.Since)
+ since, err = util.ParseInputTime(query.Since, true)
if err != nil {
utils.BadRequest(w, "since", query.Since, err)
return
@@ -73,7 +73,7 @@ func LogsFromContainer(w http.ResponseWriter, r *http.Request) {
var until time.Time
if _, found := r.URL.Query()["until"]; found {
if query.Until != "0" {
- until, err = util.ParseInputTime(query.Until)
+ until, err = util.ParseInputTime(query.Until, false)
if err != nil {
utils.BadRequest(w, "until", query.Until, err)
return