Fix race condition in Livepeer process uploader
This commit is contained in:
parent
c466e6e513
commit
e20d8fae8c
1 changed files with 1 additions and 1 deletions
|
@ -444,7 +444,6 @@ void uploadThread(void * num){
|
|||
was422 = false;
|
||||
prevURL.clear();
|
||||
mySeg.fullyWritten = false;
|
||||
mySeg.fullyRead = true;
|
||||
//Wait your turn
|
||||
while (myNum != insertTurn && conf.is_active){Util::sleep(100);}
|
||||
if (!conf.is_active){return;}//Exit early on shutdown
|
||||
|
@ -454,6 +453,7 @@ void uploadThread(void * num){
|
|||
++statFailParse;
|
||||
FAIL_MSG("Non-multipart response received - this version only works with multipart!");
|
||||
}
|
||||
mySeg.fullyRead = true;
|
||||
insertTurn = (insertTurn + 1) % PRESEG_COUNT;
|
||||
break;//Success: no need to retry
|
||||
}else if (upper.getStatusCode() == 422){
|
||||
|
|
Loading…
Add table
Reference in a new issue