char fname[PATH_MAX];
if (nsjconf->cgroup_net_cls_classid != (unsigned int)0) {
char net_cls_classid_str[512];
- snprintf(net_cls_classid_str, sizeof(net_cls_classid_str), "0x%x", nsjconf->cgroup_net_cls_classid);
+ snprintf(net_cls_classid_str, sizeof(net_cls_classid_str), "0x%x",
+ nsjconf->cgroup_net_cls_classid);
snprintf(fname, sizeof(fname), "%s/net_cls.classid", net_cls_cgroup_path);
LOG_D("Setting '%s' to '%s'", fname, net_cls_classid_str);
- if (!utilWriteBufToFile(
- fname, net_cls_classid_str, strlen(net_cls_classid_str), O_WRONLY | O_CLOEXEC)) {
+ if (!utilWriteBufToFile(fname, net_cls_classid_str, strlen(net_cls_classid_str),
+ O_WRONLY | O_CLOEXEC)) {
LOG_E("Could not update net_cls cgroup classid");
return false;
}
}
}
-__rlim64_t cmdlineParseRLimit(int res, const char* optarg, unsigned long mul)
+uint64_t cmdlineParseRLimit(int res, const char* optarg, unsigned long mul)
{
if (strcasecmp(optarg, "inf") == 0) {
return RLIM64_INFINITY;
"provided)",
res, optarg);
}
- __rlim64_t val = strtoull(optarg, NULL, 0) * mul;
+ uint64_t val = strtoull(optarg, NULL, 0) * mul;
if (val == ULLONG_MAX && errno != 0) {
PLOG_F("strtoul('%s', 0)", optarg);
}
#include "nsjail.h"
-__rlim64_t cmdlineParseRLimit(int res, const char* optarg, unsigned long mul);
+uint64_t cmdlineParseRLimit(int res, const char* optarg, unsigned long mul);
void cmdlineLogParams(struct nsjconf_t* nsjconf);
bool cmdlineParse(int argc, char* argv[], struct nsjconf_t* nsjconf);
bool keep_env;
bool keep_caps;
bool disable_no_new_privs;
- __rlim64_t rl_as;
- __rlim64_t rl_core;
- __rlim64_t rl_cpu;
- __rlim64_t rl_fsize;
- __rlim64_t rl_nofile;
- __rlim64_t rl_nproc;
- __rlim64_t rl_stack;
+ uint64_t rl_as;
+ uint64_t rl_core;
+ uint64_t rl_cpu;
+ uint64_t rl_fsize;
+ uint64_t rl_nofile;
+ uint64_t rl_nproc;
+ uint64_t rl_stack;
unsigned long personality;
bool clone_newnet;
bool clone_newuser;