File: lock_enabled.cpp

package info (click to toggle)
securefs 0.11.1%2Bds-3
  • links: PTS, VCS
  • area: main
  • in suites: bullseye
  • size: 1,684 kB
  • sloc: cpp: 11,757; python: 486; sh: 11; makefile: 7
file content (10 lines) | stat: -rw-r--r-- 256 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
#include "lock_enabled.h"
#include <atomic>

namespace securefs
{
static std::atomic_bool lock_flag{true};

bool is_lock_enabled() { return lock_flag.load(); }
void set_lock_enabled(bool value) { return lock_flag.store(value); }
}    // namespace securefs