CubicaLabs / IDASynergy

A combination of an IDAPython Plugin and a control version system that result in a new reverse engineering collaborative addon for IDA Pro. By
http://cubicalabs.com/
MIT License
91 stars 18 forks source link

Plugin uses all CPU #3

Open mattypiper opened 8 years ago

mattypiper commented 8 years ago

When IDASynergy is installed (made some mods to work with 6.9), idaq64.exe pegs one of my CPU cores.

great plugin otherwise!

mattypiper commented 8 years ago

Issue is related to the timer created in the start_plugin function in IDASynergy.py.

https://github.com/CubicaLabs/IDASynergy/blob/master/IDASynergy/IDASynergy.py#L586

Finding a better way to register the menu hooks would be a better way to fix this issue. But for now, all that needs to be done to stop pegging the CPU is to change line 582 from returning 0 to returning -1 because the work of the timer is complete, and the timer should not be executed again. Returning 0 basically says "run this timer again, immediately" which is not good. The IDA API for register timer says to return -1 to unregister the timer.