Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

A question about some codes #7

Closed
pathbox opened this issue May 7, 2018 · 2 comments
Closed

A question about some codes #7

pathbox opened this issue May 7, 2018 · 2 comments

Comments

@pathbox
Copy link

pathbox commented May 7, 2018

Hi,
I read the source codes from gracehttp, I don't understand the code:

// set graceful restart env flag
	envs := []string{}
	for _, value := range os.Environ() {
		if value != GRACEFUL_ENVIRON_STRING {
			envs = append(envs, value)
		}
	}
	envs = append(envs, GRACEFUL_ENVIRON_STRING)

In my options, just like:

envs = append(envs, GRACEFUL_ENVIRON_STRING)

Is it enough?

@tabalt
Copy link
Owner

tabalt commented May 7, 2018

主要是想把其他可能有的环境变量都带过去

@pathbox
Copy link
Author

pathbox commented May 8, 2018

我明白了,是我之前看错了,谢谢

@tabalt tabalt closed this as completed May 8, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants