This commit is contained in:
xx
2024-06-06 14:35:48 +08:00
parent e0166819fc
commit 4a6e1b4a2e
2 changed files with 3 additions and 3 deletions

View File

@@ -22,8 +22,8 @@
#define DEBUG_LOG_PPST_SET 1
#define DEBUG_LOG_SETSQL 1
#define DEBUG_LOG_PPST_SET 0
#define DEBUG_LOG_SETSQL 0
ylib::mysql::conn::conn()
{
m_handle = nullptr;

View File

@@ -65,7 +65,7 @@ bool ylib::file_io::open(const std::string &filepath,bool only_read, bool auto_c
std::ofstream outfile(filepath, std::ios::binary);
outfile.close();
// 再次尝试打开文件
m_stream->open(filepath, std::ios::in | std::ios::out | std::ios::binary);
m_stream->open(filepath, std::ios::in | std::ios::out | std::ios::binary | std::ios::app);
if (!m_stream->is_open()) {
m_lastErrorDesc = "Failed to open or create file: " + filepath;
close();