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

fix(server): Fix connection bug #695

Merged
merged 1 commit into from
Jan 16, 2023

Conversation

dranikpg
Copy link
Contributor

Fixes #694

Signed-off-by: Vladislav Oleshko <[email protected]>
Copy link
Contributor Author

@dranikpg dranikpg left a comment

Choose a reason for hiding this comment

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

Should I add a test? Its a bit messy there and the values are hard to access, so I'd need to tear it apart a little

Comment on lines -210 to -212
if (msg->storage.size() < capacity) {
msg->storage.resize(capacity);
}
Copy link
Contributor Author

Choose a reason for hiding this comment

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

I replaced it with just resize, because resizing to a smaller values doesn't actually shrink the storage to fit. The tail range is trivially destructible, so it should be no difference?

@dranikpg dranikpg merged commit daf5473 into dragonflydb:main Jan 16, 2023
@dranikpg dranikpg deleted the fix-dfly-connection branch February 27, 2023 16:39
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.

Bug inside dragonfly connection
2 participants