Boost C++ Libraries: Ticket #954: boost::dynamic_properties has no copy-constructor https://svn.boost.org/trac10/ticket/954 <p> The class boost::dynamic_properties, defined in boost/dynamic_property_map.hpp, has no supplied copy-constructor or assignment operator. Therefore the compiler gives it one. Since dynamic_properties manipulates pointers to its stored dynamic_property_map objects, this supplied constructor is not valid and leads to a crash. </p> <p> Here is a program which crashes in this way: </p> <pre class="wiki">#include &lt;boost/dynamic_property_map.hpp&gt; int main() { std::map&lt;long,long&gt; my_map; boost::associative_property_map&lt;std::map&lt;long,long&gt; &gt; apm(my_map); boost::dynamic_properties dp; dp.property("property",apm); boost::dynamic_properties dp2(dp); // crash occurs when dp is destructed. return 0; } </pre> en-us Boost C++ Libraries /htdocs/site/boost.png https://svn.boost.org/trac10/ticket/954 Trac 1.4.3 gavinband@… Sat, 12 May 2007 16:55:45 GMT <link>https://svn.boost.org/trac10/ticket/954#comment:1 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/954#comment:1</guid> <description> <p> Apologies, the component should be "property maps" not "building boost". </p> </description> <category>Ticket</category> </item> <item> <dc:creator>René Rivera</dc:creator> <pubDate>Thu, 24 May 2007 02:37:55 GMT</pubDate> <title>component changed; owner, severity set https://svn.boost.org/trac10/ticket/954#comment:2 https://svn.boost.org/trac10/ticket/954#comment:2 <ul> <li><strong>owner</strong> set to <span class="trac-author">Douglas Gregor</span> </li> <li><strong>component</strong> <span class="trac-field-old">Building Boost</span> → <span class="trac-field-new">property_map</span> </li> <li><strong>severity</strong> → <span class="trac-field-new">Showstopper</span> </li> </ul> Ticket Marshall Clow Thu, 12 Jul 2007 15:19:18 GMT owner changed https://svn.boost.org/trac10/ticket/954#comment:3 https://svn.boost.org/trac10/ticket/954#comment:3 <ul> <li><strong>owner</strong> changed from <span class="trac-author">Douglas Gregor</span> to <span class="trac-author">doug_gregor</span> </li> </ul> <p> Assigned to "doug_gregor" instead of nonexistent user "dgregor" </p> Ticket Andrew Sutton Thu, 06 Sep 2007 15:09:54 GMT status, version, severity changed; resolution set https://svn.boost.org/trac10/ticket/954#comment:4 https://svn.boost.org/trac10/ticket/954#comment:4 <ul> <li><strong>status</strong> <span class="trac-field-old">new</span> → <span class="trac-field-new">closed</span> </li> <li><strong>version</strong> <span class="trac-field-old">release 1.34.0</span> → <span class="trac-field-new">Boost Development Trunk</span> </li> <li><strong>resolution</strong> → <span class="trac-field-new">fixed</span> </li> <li><strong>severity</strong> <span class="trac-field-old">Showstopper</span> → <span class="trac-field-new">Problem</span> </li> </ul> <p> Added a new virtual clone() function (i.e., virtual copy constructor) to dynamic_property_map and its derived, template adaptor. This feature is used in the new copy constructor for dynamic_properties. Added a test for it in the unit test. </p> Ticket