PITimer important fix! ASCII-art start ...

git-svn-id: svn://db.shs.com.ru/pip@94 12ceb7fc-bf1f-11e4-8940-5bc7170c53b5
This commit is contained in:
2015-04-14 14:46:46 +00:00
parent 86f25eddde
commit 2fd1bdfe53
15 changed files with 215 additions and 57 deletions

View File

@@ -251,6 +251,16 @@ bool PIFile::isExists(const PIString & path) {
}
bool PIFile::remove(const PIString & path) {
#ifdef WINDOWS
if (PIDir::isExists(path))
return RemoveDirectory(path.data()) > 0;
else
#endif
return ::remove(path.data()) == 0;
}
PIString PIFile::constructFullPath() const {
return fullPathPrefix() + "://" + path();
}

View File

@@ -255,7 +255,7 @@ public:
static bool isExists(const PIString & path);
//! Remove file with path "path" and returns if remove was successful
static bool remove(const PIString & path) {return std::remove(path.data()) == 0;}
static bool remove(const PIString & path);
//! Rename file with path "from" to path "to" and returns if rename was successful
static bool rename(const PIString & from, const PIString & to) {return ::rename(from.data(), to.data()) == 0;}

View File

@@ -770,7 +770,6 @@ void PIProtocol::send() {
//lock();
//memcpy(packet, sendDataPtr, sendDataSize);
//unlock();
//cout << "**send" << endl;
if (!aboutSend()) return;
if (sendDataPtr == 0 || sendDataSize == 0) return;
if (history_write_send) {