php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #72678 posix_setrlimit does not work as excpected on AIX
Submitted: 2016-07-26 13:40 UTC Modified: 2021-11-09 12:12 UTC
Votes:2
Avg. Score:4.0 ± 1.0
Reproduced:0 of 1 (0.0%)
From: matthieu dot sarter dot external at atos dot net Assigned:
Status: Open Package: POSIX related
PHP Version: 7.0.9 OS: AIX
Private report: No CVE-ID: None
View Add Comment Developer Edit
Anyone can comment on a bug. Have a simpler test case? Does it work for you on a different platform? Let us know!
Just going to say 'Me too!'? Don't clutter the database with that please — but make sure to vote on the bug!
Your email address:
MUST BE VALID
Solve the problem:
48 - 44 = ?
Subscribe to this entry?

 
 [2016-07-26 13:40 UTC] 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.


Patches

php-7.0.9-aix-setrlimit.patch (last revision 2016-07-26 13:41 UTC by matthieu dot sarter dot external at atos dot net)

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2021-11-09 12:12 UTC] cmb@php.net
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>
 
PHP Copyright © 2001-2022 The PHP Group
All rights reserved.
Last updated: Tue Oct 04 23:05:52 2022 UTC