[PD-dev] PDContainer h_map fix

Lorenz Schori lorenz.schori at gmx.ch
Tue Oct 4 12:42:37 CEST 2005


hi

there is (at least) one bug in the PDContainer external which brought  
pd-0.39 miller to crash on my macos x 10.4.2 powerbook g4. map  
MapBase::get() does not check if an element was actually found for  
the key and may return garbage data which leads to the crash.  
attached is a patch which fixes this issue using a pointer instead of  
a reference as return value and setting it to NULL if the key has no  
element associated with.

i did not look into the other classes which may have similiar  
problems (multimap?,set?,...).

  - lorenz



-------------- next part --------------
A non-text attachment was scrubbed...
Name: PDContainer-mapfix.patch
Type: application/octet-stream
Size: 2694 bytes
Desc: not available
URL: <http://lists.puredata.info/pipermail/pd-dev/attachments/20051004/39062ecc/attachment.obj>


More information about the Pd-dev mailing list