soyuka / pidusage

Cross-platform process cpu % and memory usage of a PID
MIT License
512 stars 55 forks source link

callback called twice on Windows #22

Closed vmarchaud closed 8 years ago

vmarchaud commented 8 years ago

On Windows, its happen that error event and close event are both called, that result on callback function called twice

(sorry for tabs bug)

soyuka commented 8 years ago

Can you test my branch? Thx!

soyuka commented 8 years ago

Bump, I removed error event, close is getting the code which should be enough to know if an error happened.

vmarchaud commented 8 years ago

Yep, working on my Windows 7, but you still have a misplaced parenthesis on line 147.

soyuka commented 8 years ago

Nice catch, thanks