MCPcopy Create free account
hub / github.com/Profactor/cv-plot / TempFile

Method TempFile

CvPlot/ext/catch2/inc/catch.hpp:11949–11960  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

11947
11948#if defined(_MSC_VER)
11949 TempFile::TempFile() {
11950 if (tmpnam_s(m_buffer)) {
11951 CATCH_RUNTIME_ERROR("Could not get a temp filename");
11952 }
11953 if (fopen_s(&m_file, m_buffer, "w")) {
11954 char buffer[100];
11955 if (strerror_s(buffer, errno)) {
11956 CATCH_RUNTIME_ERROR("Could not translate errno to a string");
11957 }
11958 CATCH_RUNTIME_ERROR("Could not open the temp file: '" << m_buffer << "' because: " << buffer);
11959 }
11960 }
11961#else
11962 TempFile::TempFile() {
11963 m_file = std::tmpfile();

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected