Commit fe4a0007 authored by yiwenshao's avatar yiwenshao

do not show length in bigint and log should be fulshed

parent 680a9896
...@@ -162,6 +162,7 @@ operator<<(std::ostream &out, Create_field &f) ...@@ -162,6 +162,7 @@ operator<<(std::ostream &out, Create_field &f)
case MYSQL_TYPE_INT24: case MYSQL_TYPE_INT24:
case MYSQL_TYPE_LONG: case MYSQL_TYPE_LONG:
case MYSQL_TYPE_LONGLONG: case MYSQL_TYPE_LONGLONG:
break;//shaoyiwen omit length here
case MYSQL_TYPE_STRING: case MYSQL_TYPE_STRING:
if (f.length) if (f.length)
out << "(" << f.length << ")"; out << "(" << f.length << ")";
......
...@@ -10,6 +10,7 @@ logToFile::logToFile(std::string filename){ ...@@ -10,6 +10,7 @@ logToFile::logToFile(std::string filename){
logToFile& logToFile&
logToFile::operator<<(std::string record) { logToFile::operator<<(std::string record) {
fwrite(record.c_str(),1,record.size(),logfileHandler); fwrite(record.c_str(),1,record.size(),logfileHandler);
fflush(logfileHandler);
return *this; return *this;
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment