-
Notifications
You must be signed in to change notification settings - Fork 29.8k
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
util: fix isBuffer #1988
util: fix isBuffer #1988
Conversation
sigh, this spurs a linter error:
cc @silverwind |
You can also put this line before the requires |
2456ba4
to
d1b5247
Compare
Still hacky, but better! Thanks @targos, I switched the order of exports. I tried to remove the |
d1b5247
to
2eabd33
Compare
2eabd33
to
c6c706f
Compare
Alright, force pushed a fix that moves |
@brendanashworth #1892 should fix that eventually. As for the linter error, you could just put |
Also I wonder why no test has caught this circular dependency. |
@silverwind hmm, looking at #1892, it would reintroduce the dep issue because the internal module references back to the Added a small commit, summary: > util.isBuffer === Buffer.isBuffer
true |
I'd be fine with a hack if you denote it as such ( |
I'd prefer to go through with these commits, without introducing a hack / linter comment, to fix the bug. #1892 shouldn't be hard to port the changes through, as the location of the code is all that changes. |
True, shouldn't be too hard to have separate methods later. LGTM, started off a CI just to be sure: https://jenkins-iojs.nodesource.com/job/iojs+any-pr+multi/17/ |
CI failures are unrelated. @brendanashworth can you land it? This and 671e64a are pretty important fixes and we should probably do a quick patch release for them. |
@silverwind yes, landing now - 3806d87 seems to be important too, they were talking about a CVE. |
PR-URL: #1988 Reviewed-By: Roman Reiss <[email protected]>
PR-URL: #1988 Fixes: #1987 Reviewed-By: Roman Reiss <[email protected]>
PR-URL: #1988 Reviewed-By: Roman Reiss <[email protected]>
Thank you, I've merged these commits in 671e64a...626432d, in time for #1996. |
Importing Buffer caused a circular dependency issue. We need to use the
globally exported variable to get around this.
Fixes: #1987
This is just quick patch to fix the bug, I hope we can later find a better solution.