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

URls without file name in it #64

Open
y-lohse opened this issue Dec 18, 2014 · 0 comments
Open

URls without file name in it #64

y-lohse opened this issue Dec 18, 2014 · 0 comments

Comments

@y-lohse
Copy link

y-lohse commented Dec 18, 2014

Hi, there is a bug when the zip url doesn't contain the file name / contains invalid characters. For example, our update server builds urls like htttp://example.com/build.php?id=545sdfsdff48sf1cv2, but the same error can be reproduced by just using a url like http://example.com/app.zip?lol.

The error is Error: ENOENT, open 'c:\TMPPATH\build.php?id=8965c9db76b64fb9421d153476b787b2' at Error (native). I guess it's because the computed filename isn't a valid file name.

Maybe a better approach would be to inspect the headers to find a Content-disposition? Althought right now the first response headers come in after the file name has been used to unlink & create the stream.

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

1 participant