summaryrefslogtreecommitdiff
path: root/include/mts
diff options
context:
space:
mode:
authorMaksym Telychko <maksym.telychko@globallogic.com>2020-03-24 17:41:04 +0200
committerAndrii Pientsov <andrii.pientsov@globallogic.com>2020-05-26 19:48:31 +0300
commit620bd2637b40d718dd5886ce7df0a19b73ea8875 (patch)
treea1937c07a912e8c0b079b4ba3b6aa1dd82aec675 /include/mts
parentb3a9a71afdb0d6f4f104543cedba89d011ca68df (diff)
downloadlibmts-io-620bd2637b40d718dd5886ce7df0a19b73ea8875.tar.gz
libmts-io-620bd2637b40d718dd5886ce7df0a19b73ea8875.tar.bz2
libmts-io-620bd2637b40d718dd5886ce7df0a19b73ea8875.zip
MTX-3262 mpower: lockfile rewrite for interprocess communication safety
Previous implementation was not thread/interprocess safe due to pid management Fixes: Single instance guard.
Diffstat (limited to 'include/mts')
-rw-r--r--include/mts/MTS_IO_LockFile.h6
1 files changed, 1 insertions, 5 deletions
diff --git a/include/mts/MTS_IO_LockFile.h b/include/mts/MTS_IO_LockFile.h
index 730cf3c..22e641b 100644
--- a/include/mts/MTS_IO_LockFile.h
+++ b/include/mts/MTS_IO_LockFile.h
@@ -34,11 +34,8 @@
namespace MTS {
namespace IO {
-
class LockFile : MTS::NonCopyable {
-
public:
-
LockFile(const std::string& sFilePath);
virtual ~LockFile();
@@ -46,11 +43,10 @@ namespace MTS {
void unlock();
bool isLocked();
- protected:
-
private:
std::string m_sFile;
int m_iLockFd;
+ int m_iLockErr;
};
}