projects
/
systemd
/
.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
0d4c4b7
)
machinectl: accept "none" and "infinity" as specifier when dropping quotas using...
author
Lennart Poettering
<lennart@poettering.net>
Wed, 21 Oct 2015 20:41:31 +0000
(22:41 +0200)
committer
Lennart Poettering
<lennart@poettering.net>
Wed, 21 Oct 2015 23:59:25 +0000
(
01:59
+0200)
Previously, we already accepted "-" as special value for dropping
limits. Add "infinity", as that's what we support for RLIMITs and hence
should support here to. Also add "none" as that's what the btrfs tools
use.
src/machine/machinectl.c
patch
|
blob
|
history
diff --git
a/src/machine/machinectl.c
b/src/machine/machinectl.c
index 0a21ab4415b7a92ef307af2fba0a8dcf24cf69ce..d7e0395690c8d3df64fcf20fe44d92c0d21e0e48 100644
(file)
--- a/
src/machine/machinectl.c
+++ b/
src/machine/machinectl.c
@@
-2382,7
+2382,7
@@
static int set_limit(int argc, char *argv[], void *userdata) {
uint64_t limit;
int r;
- if (
streq(argv[argc-1], "-
"))
+ if (
STR_IN_SET(argv[argc-1], "-", "none", "infinity
"))
limit = (uint64_t) -1;
else {
r = parse_size(argv[argc-1], 1024, &limit);