mirror of
https://github.com/EDCD/EDMarketConnector.git
synced 2025-06-07 10:53:26 +03:00
'import fcntl' failing means we need to lie about no other instances.
This commit is contained in:
parent
11b1c436a7
commit
b0f52b3d55
@ -177,6 +177,7 @@ if __name__ == '__main__': # noqa: C901
|
|||||||
except ImportError:
|
except ImportError:
|
||||||
logger.warning("Not on win32 and we have no fcntl, can't use a file lock!"
|
logger.warning("Not on win32 and we have no fcntl, can't use a file lock!"
|
||||||
"Allowing multiple instances!")
|
"Allowing multiple instances!")
|
||||||
|
return True # Lie about there being no other instances
|
||||||
|
|
||||||
try:
|
try:
|
||||||
fcntl.flock(journal_dir_lockfile, fcntl.LOCK_EX | fcntl.LOCK_NB)
|
fcntl.flock(journal_dir_lockfile, fcntl.LOCK_EX | fcntl.LOCK_NB)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user