Skip to content

Commit

Permalink
fix:删除无效的dmp部分
Browse files Browse the repository at this point in the history
  • Loading branch information
GengGode committed Feb 14, 2023
2 parents 3aa74cb + fa807dc commit f9db073
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
8 changes: 4 additions & 4 deletions cvAutoTrack/src/ErrorCode.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -291,7 +291,7 @@ ErrorCode& ErrorCode::operator=(const std::pair<int, string>& err_code_msg)
else
{
//writeFile("%s | 错误代码:%-6d,错误信息:%s\n", time_stamp().c_str(), code, msg.c_str());
if (isUseFile == false) return *this;
if (is_use_file == false) return *this;
if (log_file.is_open() == false)
{
log_file.open("./autoTrack.log", std::ios::in | std::ios::out | std::ios::app);
Expand All @@ -307,7 +307,7 @@ ErrorCode& ErrorCode::operator=(const std::pair<int, string>& err_code_msg)

bool ErrorCode::disableWirteFile()
{
isUseFile = false;
is_use_file = false;
if (log_file.is_open())
{
log_file.close();
Expand All @@ -317,13 +317,13 @@ bool ErrorCode::disableWirteFile()

bool ErrorCode::enableWirteFile()
{
isUseFile = true;
is_use_file = true;
return true;
}

//int ErrorCode::writeFile(char const* const format ,...)
//{
// if (isUseFile == false) return -1;
// if (is_use_file == false) return -1;
// if (fptr == nullptr)
// {
// fopen_s(&fptr, "./autoTrack.log", "w+");
Expand Down
2 changes: 1 addition & 1 deletion cvAutoTrack/src/ErrorCode.h
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ using namespace std;
class ErrorCode
{
std::fstream log_file;
bool isUseFile = false;
bool is_use_file = false;
private:
ErrorCode();

Expand Down

0 comments on commit f9db073

Please sign in to comment.