diff options
author | Noriko Hosoi <nhosoi@redhat.com> | 2006-02-28 03:00:14 +0000 |
---|---|---|
committer | Noriko Hosoi <nhosoi@redhat.com> | 2006-02-28 03:00:14 +0000 |
commit | 2ab1b4d64d3d2a718bade5161c2ec2c834111f7b (patch) | |
tree | 7458e68e56824d534f349c87bc51c3c23caeee16 /lib/base | |
parent | 0402bb5e22f9c422ce2942d0c07735aee76fe1f4 (diff) | |
download | ds-2ab1b4d64d3d2a718bade5161c2ec2c834111f7b.tar.gz ds-2ab1b4d64d3d2a718bade5161c2ec2c834111f7b.tar.xz ds-2ab1b4d64d3d2a718bade5161c2ec2c834111f7b.zip |
Fixing nightly build
Changes:
1) NSPR_RELDATE: v4.6.1 --> v4.6
2) ICU_LIB_VERSION: 34 --> 24
This is a temporary degrade to adjust the version to match the one in adminutil.Once adminutil is built with icu 3.4 and pushed to /s/b/c, we'd go back to 3.4.
3) lib/base/systhr.cpp: Applied NSPR sysfd table patch
4) DS version: 7.1 --> 7.2
Diffstat (limited to 'lib/base')
-rw-r--r-- | lib/base/systhr.cpp | 26 |
1 files changed, 25 insertions, 1 deletions
diff --git a/lib/base/systhr.cpp b/lib/base/systhr.cpp index 8bbfc55f..1f611fb3 100644 --- a/lib/base/systhr.cpp +++ b/lib/base/systhr.cpp @@ -47,11 +47,19 @@ #ifdef USE_NSPR #include "nspr.h" #include "private/prpriv.h" +#ifdef LINUX +# include <sys/time.h> +# include <sys/resource.h> +#else +/* This declaration should be removed when NSPR newer than v4.6 is picked up, + which should have the fix for bug 326110 + */ extern "C" { int32 PR_GetSysfdTableMax(void); int32 PR_SetSysfdTableSize(int table_size); } #endif +#endif #include "systems.h" #ifdef THREAD_WIN32 @@ -161,9 +169,25 @@ NSAPI_PUBLIC void systhread_init(char *name) { PR_Init(PR_USER_THREAD, PR_PRIORITY_NORMAL, 256); #ifdef XP_UNIX - /* XXXrobm allocate all the fd's we can... */ +#ifdef LINUX + /* + * NSPR 4.6 does not export PR_SetSysfdTableSize + * and PR_GetSysfdTableMax by mistake (NSPR Bugzilla + * bug 326110) on platforms that use GCC with symbol + * visibility, so we have to call the system calls + * directly. + */ + { + struct rlimit rlim; + if (getrlimit(RLIMIT_NOFILE, &rlim) < 0) + return; + rlim.rlim_cur = rlim.rlim_max; + (void) setrlimit(RLIMIT_NOFILE, &rlim); + } +#else PR_SetSysfdTableSize(PR_GetSysfdTableMax()); #endif +#endif } |