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

Remove extraneous arguments to construct_env #328

Merged
merged 1 commit into from
Aug 27, 2019

Conversation

tlively
Copy link
Member

@tlively tlively commented Aug 27, 2019

The code for construct_env expects the output file to be at argv[2],
but it is actually invoked in emsdk_env.{sh,fish} with $@ there
instead. Usually this is not a problem because the emdsk_env.{sh,fish}
is sourced directly from the user's shell and $@ is empty, but this
can break in scripted environments.

The $@ was added two years ago in 3b6c6b8 for no discernible reason,
but it was entirely ignored in the code until last month when #307
added a meaningful argument to construct_env but incorrectly kept the
$@.

The code for construct_env expects the output file to be at `argv[2]`,
but it is actually invoked in emsdk_env.{sh,fish} with $@ there
instead. Usually this is not a problem because the emdsk_env.{sh,fish}
is `sourced` directly from the user's shell and $@ is empty, but this
can break in scripted environments.

The $@ was added two years ago in 3b6c6b8 for no discernible reason,
but it was entirely ignored in the code until last month when emscripten-core#307
added a meaningful argument to construct_env but incorrectly kept the
$@.
@tlively tlively merged commit 1ea9c32 into emscripten-core:master Aug 27, 2019
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

Successfully merging this pull request may close these issues.

2 participants