Bug 164610 - Directory Server crashes when deleting a view
Summary: Directory Server crashes when deleting a view
Keywords:
Status: CLOSED NEXTRELEASE
Alias: None
Product: 389
Classification: Retired
Component: Personalized Views
Version: 7.1
Hardware: i686
OS: Linux
medium
high
Target Milestone: ---
Assignee: Rich Megginson
QA Contact: Orla Hegarty
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2005-07-29 09:20 UTC by Andreas Schmid
Modified: 2007-04-18 17:29 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2005-11-04 20:02:52 UTC
Embargoed:


Attachments (Terms of Use)
Example programm in Java that crashes the directory server (1.39 KB, application/octet-stream)
2005-07-29 12:12 UTC, Andreas Schmid
no flags Details

Description Andreas Schmid 2005-07-29 09:20:17 UTC
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; de-DE; rv:1.7.8) Gecko/20050511 Firefox/1.0.4

Description of problem:


Version-Release number of selected component (if applicable):


How reproducible:
Always

Steps to Reproduce:
1. Create a view
2. Delete a view
3. Repeat Step 1 and 2 until server crashes
  

Additional info:

Comment 1 Andreas Schmid 2005-07-29 12:12:41 UTC
Created attachment 117269 [details]
Example programm in Java that crashes the directory server

Comment 3 Rich Megginson 2005-08-11 17:05:19 UTC
Reviewed by: Nathan (Thanks!)
Files: ldapserver/ldap/servers/plugins/views/views.c
Branch: HEAD
Fix Description: Needed to pass in the _address_ of theCache.pCacheViews to
views_cache_add_ll_entry.  Yet another lesson in using the compiler to catch
type errors rather than casting to void*.
Platforms tested: RHEL3
Flag Day: no
Doc impact: no
QA impact: should be covered by regular nightly and manual testing
New Tests integrated into TET: none

RCS file: /cvs/dirsec/ldapserver/ldap/servers/plugins/views/views.c,v
retrieving revision 1.5
diff -u -8 -r1.5 views.c
--- ldapserver/ldap/servers/plugins/views/views.c       19 Apr 2005 22:07:36
-0000      1.5
+++ ldapserver/ldap/servers/plugins/views/views.c       11 Aug 2005 16:29:01 -0000
@@ -1524,17 +1524,17 @@
                                Slapi_Value *v;
                                slapi_attr_first_value( attr, &v );
                                theView->parentid = slapi_value_get_ulong(v);
                        }
                        else
                                theView->parentid = 0;
 
                        /* add view to the cache */
-                       views_cache_add_ll_entry((void**)theCache.pCacheViews,
(void *)theView);
+                       views_cache_add_ll_entry((void**)&theCache.pCacheViews,
(void *)theView);
                                                                               
                        views_cache_discover_parent(theView);
                        if(theView->pParent)
                               
views_cache_discover_children((viewEntry*)theView->pParent);
 
                        /* update filters */
                        for(current = theCache.pCacheViews; current != NULL;
current = current->list.pNext)
                        {




Comment 4 To Ngan 2005-11-04 20:02:52 UTC
Verified


Note You need to log in before you can comment on or make changes to this bug.