mirror of
https://github.com/systemd/systemd.git
synced 2024-11-02 02:21:44 +03:00
missing: move resource related definitions to missing_resource.h
This commit is contained in:
parent
0e7117d001
commit
6c76de27ee
@ -106,6 +106,7 @@ basic_sources = files('''
|
|||||||
missing_magic.h
|
missing_magic.h
|
||||||
missing_network.h
|
missing_network.h
|
||||||
missing_prctl.h
|
missing_prctl.h
|
||||||
|
missing_resource.h
|
||||||
missing_securebits.h
|
missing_securebits.h
|
||||||
missing_stat.h
|
missing_stat.h
|
||||||
missing_syscall.h
|
missing_syscall.h
|
||||||
|
@ -8,7 +8,6 @@
|
|||||||
#include <inttypes.h>
|
#include <inttypes.h>
|
||||||
#include <linux/falloc.h>
|
#include <linux/falloc.h>
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include <sys/resource.h>
|
|
||||||
#include <sys/socket.h>
|
#include <sys/socket.h>
|
||||||
#include <sys/syscall.h>
|
#include <sys/syscall.h>
|
||||||
|
|
||||||
@ -29,13 +28,6 @@ struct sockaddr_vm {
|
|||||||
};
|
};
|
||||||
#endif /* !HAVE_LINUX_VM_SOCKETS_H */
|
#endif /* !HAVE_LINUX_VM_SOCKETS_H */
|
||||||
|
|
||||||
#ifndef RLIMIT_RTTIME
|
|
||||||
#define RLIMIT_RTTIME 15
|
|
||||||
#endif
|
|
||||||
|
|
||||||
/* If RLIMIT_RTTIME is not defined, then we cannot use RLIMIT_NLIMITS as is */
|
|
||||||
#define _RLIMIT_MAX (RLIMIT_RTTIME+1 > RLIMIT_NLIMITS ? RLIMIT_RTTIME+1 : RLIMIT_NLIMITS)
|
|
||||||
|
|
||||||
#ifndef F_LINUX_SPECIFIC_BASE
|
#ifndef F_LINUX_SPECIFIC_BASE
|
||||||
#define F_LINUX_SPECIFIC_BASE 1024
|
#define F_LINUX_SPECIFIC_BASE 1024
|
||||||
#endif
|
#endif
|
||||||
@ -266,6 +258,7 @@ struct sockaddr_vm {
|
|||||||
#include "missing_magic.h"
|
#include "missing_magic.h"
|
||||||
#include "missing_network.h"
|
#include "missing_network.h"
|
||||||
#include "missing_prctl.h"
|
#include "missing_prctl.h"
|
||||||
|
#include "missing_resource.h"
|
||||||
#include "missing_type.h"
|
#include "missing_type.h"
|
||||||
|
|
||||||
#include "missing_syscall.h"
|
#include "missing_syscall.h"
|
||||||
|
11
src/basic/missing_resource.h
Normal file
11
src/basic/missing_resource.h
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
/* SPDX-License-Identifier: LGPL-2.1+ */
|
||||||
|
#pragma once
|
||||||
|
|
||||||
|
#include <sys/resource.h>
|
||||||
|
|
||||||
|
#ifndef RLIMIT_RTTIME
|
||||||
|
#define RLIMIT_RTTIME 15
|
||||||
|
#endif
|
||||||
|
|
||||||
|
/* If RLIMIT_RTTIME is not defined, then we cannot use RLIMIT_NLIMITS as is */
|
||||||
|
#define _RLIMIT_MAX (RLIMIT_RTTIME+1 > RLIMIT_NLIMITS ? RLIMIT_RTTIME+1 : RLIMIT_NLIMITS)
|
Loading…
Reference in New Issue
Block a user