add ifdefs to make service/instance.c compile on non-linux systems
authorFelix Fietkau <nbd@openwrt.org>
Sat, 5 Mar 2016 11:15:38 +0000 (12:15 +0100)
committerFelix Fietkau <nbd@openwrt.org>
Sat, 5 Mar 2016 11:15:38 +0000 (12:15 +0100)
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
service/instance.c

index b8602b8c49d0b0bf720def627865ad773f30e20d..f2604fef4573c7e8e66fdbb2d8fdc0a35d3c37dd 100644 (file)
@@ -122,14 +122,16 @@ static const struct rlimit_name rlimit_names[] = {
        { "data", RLIMIT_DATA },
        { "fsize", RLIMIT_FSIZE },
        { "memlock", RLIMIT_MEMLOCK },
-       { "msgqueue", RLIMIT_MSGQUEUE },
-       { "nice", RLIMIT_NICE },
        { "nofile", RLIMIT_NOFILE },
        { "nproc", RLIMIT_NPROC },
        { "rss", RLIMIT_RSS },
+       { "stack", RLIMIT_STACK },
+#ifdef linux
+       { "nice", RLIMIT_NICE },
        { "rtprio", RLIMIT_RTPRIO },
+       { "msgqueue", RLIMIT_MSGQUEUE },
        { "sigpending", RLIMIT_SIGPENDING },
-       { "stack", RLIMIT_STACK },
+#endif
        { NULL, 0 }
 };