Rename classes and small adjustments

This commit is contained in:
topjohnwu
2019-09-25 23:55:39 -04:00
parent debd1d7d54
commit 947dae4900
13 changed files with 53 additions and 57 deletions

View File

@@ -36,7 +36,7 @@ static inline void lazy_unmount(const char* mountpoint) {
}
void hide_daemon(int pid) {
RunFinally fin([=]() -> void {
run_finally fin([=]() -> void {
// Send resume signal
kill(pid, SIGCONT);
_exit(0);

View File

@@ -98,7 +98,7 @@ static int add_list(const char *pkg, const char *proc = "") {
// Critical region
{
MutexGuard lock(monitor_lock);
mutex_guard lock(monitor_lock);
hide_set.emplace(pkg, proc);
}
@@ -119,7 +119,7 @@ int add_list(int client) {
static int rm_list(const char *pkg, const char *proc = "") {
{
// Critical region
MutexGuard lock(monitor_lock);
mutex_guard lock(monitor_lock);
bool remove = false;
auto next = hide_set.begin();
decltype(next) cur;

View File

@@ -76,7 +76,7 @@ static inline long xptrace(int request, pid_t pid, void *addr = nullptr, intptr_
}
void update_uid_map() {
MutexGuard lock(monitor_lock);
mutex_guard lock(monitor_lock);
uid_proc_map.clear();
string data_path(APP_DATA_DIR);
data_path += "/0/";
@@ -336,7 +336,7 @@ void proc_monitor() {
continue;
}
bool detach = false;
RunFinally detach_task([&] {
run_finally f([&] {
if (detach)
// Non of our business now
detach_pid(pid);