-
Notifications
You must be signed in to change notification settings - Fork 342
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 #655 Repeated subscriptions result in multiple callbacks #674
base: master
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
use error, you can define the SubscribeParam variable and pass it to Subscribe,Unsubscribe
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's not the same problem #655 is trying to solve
Add duplicate check during subscription |
Codecov ReportAttention:
❗ Your organization needs to install the Codecov GitHub app to enable full functionality. Additional details and impacted files@@ Coverage Diff @@
## master #674 +/- ##
==========================================
+ Coverage 29.71% 29.93% +0.21%
==========================================
Files 40 40
Lines 3093 3097 +4
==========================================
+ Hits 919 927 +8
+ Misses 2104 2102 -2
+ Partials 70 68 -2
☔ View full report in Codecov by Sentry. |
@binbin0325 这个pr是否符合要求?pending好久了 |
符合要求,本周再重点看下 |
bug
初始化vo.SubscribeParam的SubscribeCallback属性时是值传递,导致"订阅”和"取消订阅"两次请求传入的回调函数不同,取消订阅逻辑总无法清除对应的callback从而产生这个bug #655。
fix
将SubscribeCallback定义为指针类型的函数,保证"取消订阅"请求时两次回调函数符合相等性的判断。
result