You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by "centurysys (via GitHub)" <gi...@apache.org> on 2023/02/17 07:54:43 UTC
[GitHub] [nuttx] centurysys commented on a diff in pull request #8555: libc: unistd: lib_getrlimit: return a value for RLIMIT_NOFILE request.
centurysys commented on code in PR #8555:
URL: https://github.com/apache/nuttx/pull/8555#discussion_r1109405388
##########
libs/libc/unistd/lib_getrlimit.c:
##########
@@ -55,5 +55,19 @@ int getrlimit(int resource, FAR struct rlimit *rlp)
/* This is a dummy realization to make the compiler happy */
memset(rlp, 0, sizeof(*rlp));
+
+ switch (resource)
+ {
+ case RLIMIT_NOFILE:
+ {
+ rlp->rlim_cur = 128;
+ rlp->rlim_max = 1024 * 1024; /* dummy */
Review Comment:
@xiaoxiang781216
The value is determined from CONFIG_LIBC_OPEN_MAX, I have not been able to find this definition.
Thanks for pointing this out. I will correct it.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@nuttx.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org