Re: [boost] [Boost-users] [IPC Named Mutex]

On Thu, Apr 16, 2015 at 3:01 AM, Lorenzo Trivelli < trivelli.lorenzo@konvergence.it> wrote:
I tried it also, and got the same result. I also tried with msvc-12.0, same result.
get_last_bootup_time() looks through the system event log for event ID == 6005 (event log started)...since the event log was cleared out, this is not found. I guess that is a bug in boost. One thing you could try...in interprocess's win32_api.hpp, there is another implementation of get_last_bootup_time() which uses WMI instead of the event log (there were warnings in the source about WMI not supporting hibernation/clock changes correctly, so beware). If you define BOOST_INTERPROCESS_BOOTSTAMP_IS_LASTBOOTUPTIME it should use that other version...give that a try. (in visual studio Project Properties -> C/C++ -> Preprocessor -> Preprocessor Definitions: add a semi colon ';' then the above item) That worked for me on windows 7. I submitted a pull request to automatically fallback to WMI if the event log started event isn't in the log. https://github.com/boostorg/interprocess/pull/18 Tom
participants (1)
-
Tom Kent