[systemd-commits] man/systemd.exec.xml src/load-fragment.c TODO
Lennart Poettering
lennart at kemper.freedesktop.org
Mon Apr 4 09:15:19 PDT 2011
TODO | 2 ++
man/systemd.exec.xml | 5 ++++-
src/load-fragment.c | 6 +++++-
3 files changed, 11 insertions(+), 2 deletions(-)
New commits:
commit 3d57c6ab801f4437f12948e29589e3d00c3ad9db
Author: Lennart Poettering <lennart at poettering.net>
Date: Mon Apr 4 18:15:13 2011 +0200
exec: support unlimited resources
diff --git a/TODO b/TODO
index 466dadc..494f991 100644
--- a/TODO
+++ b/TODO
@@ -25,6 +25,8 @@ F15:
Features:
+* allow port = 0 in .socket units
+
* rename systemd-logger to systemd-stdio-syslog-bridge
* introduce /usr/lib/binfmt.d/, /usr/lib/tmpfiles.d/
diff --git a/man/systemd.exec.xml b/man/systemd.exec.xml
index fb8496f..5b0d2ce 100644
--- a/man/systemd.exec.xml
+++ b/man/systemd.exec.xml
@@ -558,7 +558,10 @@
various resource limits for executed
processes. See
<citerefentry><refentrytitle>setrlimit</refentrytitle><manvolnum>2</manvolnum></citerefentry>
- for details.</para></listitem>
+ for details. Use the string
+ <varname>infinity</varname> to
+ configure no limit on a specific
+ resource.</para></listitem>
</varlistentry>
<varlistentry>
diff --git a/src/load-fragment.c b/src/load-fragment.c
index eea545c..8635bdb 100644
--- a/src/load-fragment.c
+++ b/src/load-fragment.c
@@ -30,6 +30,8 @@
#include <sys/mount.h>
#include <linux/fs.h>
#include <sys/stat.h>
+#include <sys/time.h>
+#include <sys/resource.h>
#include "unit.h"
#include "strv.h"
@@ -965,7 +967,9 @@ static int config_parse_limit(
assert(rvalue);
assert(data);
- if (safe_atollu(rvalue, &u) < 0) {
+ if (streq(rvalue, "infinity"))
+ u = (unsigned long long) RLIM_INFINITY;
+ else if (safe_atollu(rvalue, &u) < 0) {
log_error("[%s:%u] Failed to parse resource value, ignoring: %s", filename, line, rvalue);
return 0;
}
More information about the systemd-commits
mailing list