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

msg/simple: fix missing unlock when already bind #13267

Merged
merged 2 commits into from Feb 20, 2017

Conversation

Projects
None yet
4 participants
@yuyuyu101
Copy link
Member

yuyuyu101 commented Feb 6, 2017

Signed-off-by: Haomai Wang haomai@xsky.com

msg/simple: fix missing unlock when already bind
Signed-off-by: Haomai Wang <haomai@xsky.com>
@yuyuyu101

This comment has been minimized.

Copy link
Member Author

yuyuyu101 commented Feb 6, 2017

caused by #12901

@Liuchang0812

This comment has been minimized.

Copy link
Contributor

Liuchang0812 commented Feb 6, 2017

hi, @yuyuyu101

AsyncMessager::client_bind also need this patch.

@@ -312,6 +312,7 @@ int SimpleMessenger::client_bind(const entity_addr_t &bind_addr)
lock.Lock();
if (did_bind) {
assert(my_inst.addr == bind_addr);
lock.Unlock();

This comment has been minimized.

Copy link
@Liuchang0812

Liuchang0812 Feb 6, 2017

Contributor

AsyncMessager::client_bind also need this patch.

@yuyuyu101

This comment has been minimized.

Copy link
Member Author

yuyuyu101 commented Feb 6, 2017

thanks, done

@Liuchang0812
Copy link
Contributor

Liuchang0812 left a comment

lgtm thanks

@@ -396,6 +396,7 @@ int AsyncMessenger::client_bind(const entity_addr_t &bind_addr)
lock.Lock();
if (did_bind) {
assert(my_inst.addr == bind_addr);
lock.Unlock();

This comment has been minimized.

Copy link
@tchaikov

tchaikov Feb 6, 2017

Contributor

nit, better off using Mutex::Locker. or instead switch to std::mutex, and use std::lock_guard instead.

msg/async: fix missing unlock when already bind
Signed-off-by: Haomai Wang <haomai@xsky.com>

@yuyuyu101 yuyuyu101 force-pushed the yuyuyu101:wip-fix-lock branch from 7a05e7a to 067d569 Feb 18, 2017

@yuyuyu101

This comment has been minimized.

Copy link
Member Author

yuyuyu101 commented Feb 18, 2017

@tchaikov done

@tchaikov

This comment has been minimized.

@tchaikov tchaikov merged commit c119da5 into ceph:master Feb 20, 2017

3 checks passed

Signed-off-by all commits in this PR are signed
Details
Unmodifed Submodules submodules for project are unmodified
Details
default Build finished.
Details

@yuyuyu101 yuyuyu101 deleted the yuyuyu101:wip-fix-lock branch Feb 20, 2017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.