summaryrefslogtreecommitdiff
path: root/pkg/specgenutil
diff options
context:
space:
mode:
authorDaniel J Walsh <dwalsh@redhat.com>2022-08-23 10:51:21 -0400
committerDaniel J Walsh <dwalsh@redhat.com>2022-08-23 14:44:23 -0400
commit65efcdf709a83e6d013b4e65247750c97236d89a (patch)
tree2152d701bf23098b5e02af63f297820287d20368 /pkg/specgenutil
parent3bcd8047cff076d34887bd3be7ed0e5701a41a02 (diff)
downloadpodman-65efcdf709a83e6d013b4e65247750c97236d89a.tar.gz
podman-65efcdf709a83e6d013b4e65247750c97236d89a.tar.bz2
podman-65efcdf709a83e6d013b4e65247750c97236d89a.zip
Allow podman to run in an environment with keys containing spaces
Fixes: https://github.com/containers/podman/issues/15251 Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
Diffstat (limited to 'pkg/specgenutil')
-rw-r--r--pkg/specgenutil/specgen.go5
1 files changed, 1 insertions, 4 deletions
diff --git a/pkg/specgenutil/specgen.go b/pkg/specgenutil/specgen.go
index 7392e7b44..c706b396f 100644
--- a/pkg/specgenutil/specgen.go
+++ b/pkg/specgenutil/specgen.go
@@ -362,10 +362,7 @@ func FillOutSpecGen(s *specgen.SpecGenerator, c *entities.ContainerCreateOptions
// First transform the os env into a map. We need it for the labels later in
// any case.
- osEnv, err := envLib.ParseSlice(os.Environ())
- if err != nil {
- return fmt.Errorf("error parsing host environment variables: %w", err)
- }
+ osEnv := envLib.Map(os.Environ())
if !s.EnvHost {
s.EnvHost = c.EnvHost