Skip to content

[5.0] Fix off-by-one when initializing Data with discontiguous, underestimated Sequences #23253

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

Conversation

itaiferber
Copy link
Contributor

@itaiferber itaiferber commented Mar 13, 2019

What's in this pull request?
Cherry-picks #23244 to swift-5.0-branch (resolves rdar://problem/48775516)

  • Explanation: Creation of Data objects with certain sequences of bytes will drop bytes at regular intervals, leading to data loss and corruption.
  • Scope: Affects users of Data which exercise this code path both internally and externally (including major clients like Vapor and nio-redis) and their clients (scope is wide here)
  • Issue: rdar://problem/48775516
  • Risk: Low. This is an off-by-one error which is resolved and actively tested
  • Testing: Tests have been updated to demonstrably exercise this code path
  • Reviewer: Ben Cohen

@itaiferber itaiferber requested a review from a team as a code owner March 13, 2019 00:11
@itaiferber
Copy link
Contributor Author

@swift-ci Please test

@itaiferber
Copy link
Contributor Author

@swift-ci Please nominate

Copy link
Member

@lorentey lorentey left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

@airspeedswift airspeedswift merged commit 1961044 into swiftlang:swift-5.0-branch Mar 13, 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.

3 participants