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

src/butil: correct assign atomic pointer member to be NULL #2003

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

changchengx
Copy link

  1. memset assign value to var without considering var type.
  2. memset can't guarantee atomic operation

Signed-off-by: Liu, Changcheng [email protected]

1. memset assign value to var without considering var type.
2. memset can't guarantee atomic operation

Signed-off-by: Liu, Changcheng <[email protected]>
@wwbmmm
Copy link
Contributor

wwbmmm commented Nov 18, 2022

@changchengx Do you have any problem using memset ? (eg. compile error or unexpected behavior at runtime)

@changchengx
Copy link
Author

@wwbmmm No. From semantic perspective, memset doesn't consider variable type at all and guarantee atomic operation.

@serverglen
Copy link
Contributor

Could you please submit the application scenario of brpc in your company?
See #1640

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