MCPcopy Create free account
hub / github.com/InteractiveComputerGraphics/TriangleMeshDistance / TempFile

Method TempFile

tests/catch.hpp:9586–9597  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

9584
9585#if defined(_MSC_VER)
9586 TempFile::TempFile() {
9587 if (tmpnam_s(m_buffer)) {
9588 CATCH_RUNTIME_ERROR("Could not get a temp filename");
9589 }
9590 if (fopen_s(&m_file, m_buffer, "w")) {
9591 char buffer[100];
9592 if (strerror_s(buffer, errno)) {
9593 CATCH_RUNTIME_ERROR("Could not translate errno to a string");
9594 }
9595 CATCH_RUNTIME_ERROR("Coul dnot open the temp file: '" << m_buffer << "' because: " << buffer);
9596 }
9597 }
9598#else
9599 TempFile::TempFile() {
9600 m_file = std::tmpfile();

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected