Pantek Library
Hosting Provided By
CybrHost
High Speed Hosting

DO NOT REPLY [Bug 12757] - mod_ldap cache tries to open an existing shared memory file

From: <bugzilla(at)apache.org>
Date: Fri Jan 10 2003 - 17:58:22 EST


DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT <http://nagoya.apache.org/bugzilla/show_bug.cgi?id=12757>. ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND INSERTED IN THE BUG DATABASE. http://nagoya.apache.org/bugzilla/show_bug.cgi?id=12757

mod_ldap cache tries to open an existing shared memory file

  • Additional Comments From scooter@gene.com 2003-01-10 22:58 ------- Actually, wouldn't it be better to just attach to the named file? I implemented something like this:

cvs diff -c util_ldap_cache.c
Index: util_ldap_cache.c



RCS file:
/usr/src/cvs/cvsroot/contrib/Apache/modules/experimental/util_ldap_cache.c,v retrieving revision 1.1.1.1
diff -c -r1.1.1.1 util_ldap_cache.c
*** util_ldap_cache.c 8 Oct 2002 20:49:28 -0000 1.1.1.1 --- util_ldap_cache.c 10 Jan 2003 22:55:51 -0000
  • 296,304 **** apr_status_t result;
      result = apr_shm_create(&util_ldap_shm, reqsize, "/tmp/ldap_cache", pool);

! if (result != APR_SUCCESS) {
return result; - } /* This will create a rmm "handler" to get into the shared memory area */ apr_rmm_init(&util_ldap_rmm, NULL, --- 296,310 ---- apr_status_t result; result = apr_shm_create(&util_ldap_shm, reqsize, "/tmp/ldap_cache", pool);
! if (result == EEXIST) {
! /*
! * The cache could have already been created (i.e. we may be a child
process). See
! * if we can attach to the existing shared memory
! */
! result = apr_shm_attach(&util_ldap_shm, "/tmp/ldap_cache", pool);
! }
! if (result != APR_SUCCESS)
return result; /* This will create a rmm "handler" to get into the shared memory area */ apr_rmm_init(&util_ldap_rmm, NULL,

and it seems to work for me.



To unsubscribe, e-mail: bugs-unsubscribe@httpd.apache.org For additional commands, e-mail: bugs-help@httpd.apache.org Received on Fri Jan 10 22:56:58 2003

This archive was generated by hypermail 2.1.8 : Wed Aug 23 2006 - 16:44:18 EDT


Contact Us  Legal Notices  Order Services Online 
Pantek Home  Privacy Policy  IT news  Site Map  Pantek Library