Changeset 155a7cf in opengl-game for logger.cpp
- Timestamp:
- May 10, 2019, 7:42:17 PM (5 years ago)
- Branches:
- feature/imgui-sdl, master, points-test
- Children:
- bae0911
- Parents:
- e6bc0f4
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
logger.cpp
re6bc0f4 r155a7cf 4 4 #include <ctime> 5 5 #include <cstdarg> 6 #include <iostream> 7 8 using namespace std; 6 9 7 10 bool restart_gl_log() { 8 11 FILE* file = fopen(GL_LOG_FILE, "w"); 9 12 if (!file) { 10 fprintf(stderr, "ERROR: could not open GL_LOG_FILE log file %s for writing\n", GL_LOG_FILE);13 cerr << "ERROR: could not open GL_LOG_FILE log file " << GL_LOG_FILE << " for writing" << endl; 11 14 return false; 12 15 } … … 22 25 FILE* file = fopen(GL_LOG_FILE, "a"); 23 26 if (!file) { 24 fprintf(stderr, "ERROR: could not open GL_LOG_FILE log file %s for appending\n", GL_LOG_FILE);27 cerr << "ERROR: could not open GL_LOG_FILE log file " << GL_LOG_FILE << " for appending" << endl; 25 28 return false; 26 29 } … … 37 40 FILE* file = fopen(GL_LOG_FILE, "a"); 38 41 if (!file) { 39 fprintf(stderr, "ERROR: could not open GL_LOG_FILE log file %s for appending\n", GL_LOG_FILE);42 cerr << "ERROR: could not open GL_LOG_FILE log file " << GL_LOG_FILE << " for appending" << endl; 40 43 return false; 41 44 }
Note:
See TracChangeset
for help on using the changeset viewer.