mirror of
https://github.com/caddyserver/caddy.git
synced 2026-11-13 04:04:14 +00:00
Fix for invalid environment variable names used on windows that start with an equals symbol. Even though this contradicts the Microsoft docs.
This commit is contained in:
1 parent
454b1e3939
commit
f372f5fce7
2 files changed
+15
-1
No files matched your search
@@ -64,7 +64,7 @@ func (c Context) Env() map[string]string {
|
||||
envVars := make(map[string]string, len(osEnv))
|
||||
for _, env := range osEnv {
|
||||
data := strings.SplitN(env, "=", 2)
|
||||
if len(data) == 2 {
|
||||
if len(data) == 2 && len(data[0]) > 0 {
|
||||
envVars[data[0]] = data[1]
|
||||
}
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user