summaryrefslogtreecommitdiff
path: root/libpod
diff options
context:
space:
mode:
Diffstat (limited to 'libpod')
-rw-r--r--libpod/container_api.go8
-rw-r--r--libpod/runtime.go2
2 files changed, 3 insertions, 7 deletions
diff --git a/libpod/container_api.go b/libpod/container_api.go
index 93becb80d..41a131ea2 100644
--- a/libpod/container_api.go
+++ b/libpod/container_api.go
@@ -666,14 +666,10 @@ func (c *Container) Batch(batchFunc func(*Container) error) error {
newCtr.valid = true
newCtr.batched = true
-
- if err := batchFunc(newCtr); err != nil {
- return err
- }
-
+ err := batchFunc(newCtr)
newCtr.batched = false
- return c.save()
+ return err
}
// Sync updates the current state of the container, checking whether its state
diff --git a/libpod/runtime.go b/libpod/runtime.go
index f012d66c2..1b26f851f 100644
--- a/libpod/runtime.go
+++ b/libpod/runtime.go
@@ -508,7 +508,7 @@ func makeRuntime(runtime *Runtime) (err error) {
// Set up a firewall backend
backendType := ""
- if os.Geteuid() != 0 {
+ if rootless.IsRootless() {
backendType = "none"
}
fwBackend, err := firewall.GetBackend(backendType)