Issue
When I change a parameter in client.rabbitcontrol.cc, sometimes oF app crashes on macOS and Ubuntu.
This only happens when I have a ofParameter which is frequently updated from oF app.
The crash happens randomly as far as I use it in a normal way.
Location of the issue
parameterserver.cpp L189-L198
|
for (auto& p : parameterManager->dirtyParameter) { |
|
|
|
// TODO send COMMAND_UPDATEVALUE |
|
command_t cmd = COMMAND_UPDATE; |
|
|
|
if (p.second->onlyValueChanged()) |
|
{ |
|
cmd = COMMAND_UPDATEVALUE; |
|
} |
|
|
|
Packet packet(cmd, p.second); |
|
sendPacket(packet); |
|
} |
- sometimes p or p->second becomes nullptr
- sometimes iterator(of for loop) fails to increment
How to regenerate issue
- add following line in example app (ofxRabbitControl/example/src/ofApp.cpp)
void ofApp::update(){
for(int i=0; i<10000; i++){
int32Param = ofRandom(0, 100);
floatParam = ofRandom(0, 10.0f);
}
}
- run oF app and connect via client.rabbitcontrol.cc
- keep moving some of GUI slider or color palette quickly
Environment
A
- macOS 10.15.7
- Xcode 12.4
- oF 0.11.0
- Latest master branch with fake ofFloatColor fix
B
- Ubuntu 20.04
- CLion
- oF 0.11.0
- Latest master branch with fake ofFloatColor fix
Issue
When I change a parameter in client.rabbitcontrol.cc, sometimes oF app crashes on macOS and Ubuntu.
This only happens when I have a ofParameter which is frequently updated from oF app.
The crash happens randomly as far as I use it in a normal way.
Location of the issue
parameterserver.cpp L189-L198
ofxRabbitControl/src/rabbitControl/parameterserver.cpp
Lines 186 to 198 in 6ef07ef
How to regenerate issue
Environment
A
B