MCPcopy Create free account
hub / github.com/OpenStarbound/OpenStarbound / acquireLock

Method acquireLock

source/core/StarLockFile_windows.cpp:13–18  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

11int64_t const LockFile::MaximumSleepMillis;
12
13Maybe<LockFile> LockFile::acquireLock(String const& filename, int64_t lockTimeout) {
14 LockFile lock(std::move(filename));
15 if (lock.lock(lockTimeout))
16 return std::move(lock);
17 return {};
18}
19
20LockFile::LockFile(String const& filename) : m_filename(std::move(filename)) {}
21

Callers

nothing calls this directly

Calls 1

lockMethod · 0.45

Tested by

no test coverage detected