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

Implement better buffer boundary matching algorithm #1

Open
soareschen opened this issue Mar 17, 2015 · 0 comments
Open

Implement better buffer boundary matching algorithm #1

soareschen opened this issue Mar 17, 2015 · 0 comments

Comments

@soareschen
Copy link
Member

Currently the multipart stream handler uses a very naive algorithm for matching boundary from multiple slices of buffers.

We want to avoid concatenating the buffers into single buffer because then it would be too large for finding the end boundary. This is unless io.js concatenates buffers without allocating and copying content into a contiguous concatenated buffer, which I haven't verify.

Until then, we need to consider using more efficient boundary matching algorithms such as the Boyer–Moore string search algorithm.

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