mirror of
https://github.com/trapexit/mergerfs.git
synced 2026-10-26 19:01:56 -04:00
attempt to set priority to -10 on startup. closes #65
This commit is contained in:
parent
7552ad6781
commit
5fb277529f
3 changed files with 15 additions and 3 deletions
|
|
@ -40,7 +40,7 @@ namespace mergerfs
|
|||
}
|
||||
|
||||
int
|
||||
maxout_rlimit(int resource)
|
||||
maxout_rlimit(const int resource)
|
||||
{
|
||||
int rv;
|
||||
struct rlimit rlim;
|
||||
|
|
@ -78,5 +78,13 @@ namespace mergerfs
|
|||
{
|
||||
return maxout_rlimit(RLIMIT_FSIZE);
|
||||
}
|
||||
|
||||
int
|
||||
setpriority(const int prio)
|
||||
{
|
||||
const int SELF = 0;
|
||||
|
||||
return ::setpriority(PRIO_PROCESS,SELF,prio);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue