From: Todd C. Miller Date: Fri, 25 Jan 2002 18:38:22 +0000 (+0000) Subject: HP-UX 9.x has RLIMIT_* but no RLIM_INFINITY. If there is no X-Git-Tag: SUDO_1_6_6~11 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=d1bb1bc09976d8d53c5e634640fc6a59b5de3786;p=sudo HP-UX 9.x has RLIMIT_* but no RLIM_INFINITY. If there is no RLIM_INFINITY, just pretend it is -1. This works because we only check for RLIM_INFINITY and do not set anything to that value. --- diff --git a/compat.h b/compat.h index 5ecc83734..57241b3a3 100644 --- a/compat.h +++ b/compat.h @@ -245,4 +245,12 @@ typedef struct sigaction sigaction_t; # endif #endif +/* + * HP-UX 9.x has RLIMIT_* but no RLIM_INFINITY. + * Using -1 works because we only check for RLIM_INFINITY and do not set it. + */ +#ifndef RLIM_INFINITY +# define RLIM_INFINITY (-1) +#endif + #endif /* _SUDO_COMPAT_H */