DescriptionFix a race problem in SetGlobalEngine and add set_global_engine in python library
The race problem:
1. global engine == A
2. call SetGlobalEngine(B) asynchronously
3. call SetGlobalEngine(A) immediately
3.1 Because step 2 is not finished, so the global engine is still A,
and SetGlobalEngine(A) returns sucessfully.
4. SetGlobalEngine(B) is completed and the global engine becomes B
BUG=http://crosbug.com/12414
TEST=Linux desktop
Patch Set 1 #Patch Set 2 : update #
MessagesTotal messages: 2
|