| 56 | } |
| 57 | |
| 58 | static bool file_is_empty(const std::string & path) { |
| 59 | std::ifstream f; |
| 60 | f.exceptions(std::ifstream::failbit | std::ifstream::badbit); |
| 61 | f.open(path.c_str(), std::ios::in | std::ios::binary | std::ios::ate); |
| 62 | return f.tellg() == 0; |
| 63 | } |
| 64 | |
| 65 | #if defined (__unix__) || (defined (__APPLE__) && defined (__MACH__)) || defined (_WIN32) |
| 66 | static void sigint_handler(int signo) { |