MCPcopy Create free account
hub / github.com/OpenZWave/open-zwave / FormatSehExceptionMessage

Function FormatSehExceptionMessage

cpp/test/src/gtest.cc:2333–2340  ·  view source on GitHub ↗

Adds an "exception thrown" fatal failure to the current test. This function returns its result via an output parameter pointer because VC++ prohibits creation of objects with destructors on stack in functions using __try (see error C2712).

Source from the content-addressed store, hash-verified

2331// prohibits creation of objects with destructors on stack in functions
2332// using __try (see error C2712).
2333static std::string* FormatSehExceptionMessage(DWORD exception_code,
2334 const char* location) {
2335 Message message;
2336 message << "SEH exception with code 0x" << std::setbase(16) <<
2337 exception_code << std::setbase(10) << " thrown in " << location << ".";
2338
2339 return new std::string(message.GetString());
2340}
2341
2342#endif // GTEST_HAS_SEH
2343

Calls 1

GetStringMethod · 0.80

Tested by

no test coverage detected