Bug #72678 [Opn]: posix_setrlimit does not work as excpected on AIX

From: Date: Tue, 09 Nov 2021 12:12:09 +0000
Subject: Bug #72678 [Opn]: posix_setrlimit does not work as excpected on AIX
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-237648@lists.php.net to get a copy of this message
Edit report at https://bugs.php.net/bug.php?id=72678&edit=1

 ID:                 72678
 Updated by:         cmb@php.net
 Reported by:        matthieu dot sarter dot external at atos dot net
 Summary:            posix_setrlimit does not work as excpected on AIX
 Status:             Open
 Type:               Bug
 Package:            POSIX related
 Operating System:   AIX
 PHP Version:        7.0.9
 Block user comment: N
 Private report:     N

 New Comment:

I suggest to submit this patch as PR[1] for better visibility.
Also adding a regression test might make sense.

[1] <https://github.com/php/php-src/pulls>


Previous Comments:
------------------------------------------------------------------------
[2016-07-26 13:40:49] matthieu dot sarter dot external at atos dot net

Description:
------------
On AIX, posix_setrlimit returns true when called with $softlimit > $hardlimit and sets the soft
limit to the same value as the hard limit instead of returning false and not changing the limits
values.

This is due to the way the setrlimit call behaves in AIX.

The attached patch ensures the posix_setrlimit PHP function offers the same behaviour on AIX as on
Linux.



------------------------------------------------------------------------



--
Edit this bug report at https://bugs.php.net/bug.php?id=72678&edit=1


Thread (2 messages)

« previous php.bugs (#237648) next »