#82 Infinite loops while collecting data on Windows 7

closed-fixed
Danny Haynes
5
2009-11-10
2009-10-27
Jens Miltner
No

We have at least one machine where the data collection ends up in an infinite loop while trying to fetch data from the Windows OS. (In this case, the ovaldi tool was running on Windows 7.)

This is caused by various functions not honouring the BOOL value returned from the WIndows APIs and instead relying on GetLastError() to detect success.
Apparently, there are setups where the LastError value is not reset when a Windows API call succeeds, thus the loop is continued infinitely.

I have attached a patch that fixes these issues (at least those that we discovered) by checking the return value of the API calls and breaking the loops when the call succeeded, ignoring the GetLastError() value in the success case.
(The patch is against the 5.6 Build 3 sources.)

Discussion

  • Jonathan Baker
    Jonathan Baker
    2009-10-27

    • assigned_to: nobody --> djhaynes
     
  • Danny Haynes
    Danny Haynes
    2009-11-10

    • status: open --> closed-fixed