Boost C++ Libraries: Ticket #752: directory_iterator doesn't work with catch https://svn.boost.org/trac10/ticket/752 <pre class="wiki">Fedora Core 4, gcc version 4.0.2 20051125 (Red Hat 4.0.2-8) The next construction doesn't work (but it works if directory_iterator is changed to some other iterator or just counter): path dir_path(dir_name); directory_iterator end_itr; try { for (directory_iterator itr(dir_name); itr!=end_itr; ++itr) { try { ...... } catch (...) { cout&lt;&lt;"First catch"&lt;&lt;endl; throw 20; } } } catch (...) { cout&lt;&lt;"Second catch"&lt;&lt;endl; } Result: First catch and stucked program, "strace" shows: "futex(0x...,FUTEX_WAIT,2,NULL". </pre> en-us Boost C++ Libraries /htdocs/site/boost.png https://svn.boost.org/trac10/ticket/752 Trac 1.4.3 Marshall Clow Wed, 11 Jul 2007 16:33:34 GMT owner, status changed; severity set https://svn.boost.org/trac10/ticket/752#comment:1 https://svn.boost.org/trac10/ticket/752#comment:1 <ul> <li><strong>owner</strong> changed from <span class="trac-author">beman_dawes</span> to <span class="trac-author">Beman Dawes</span> </li> <li><strong>status</strong> <span class="trac-field-old">assigned</span> → <span class="trac-field-new">new</span> </li> <li><strong>severity</strong> → <span class="trac-field-new">Showstopper</span> </li> </ul> <p> assigning to actual user "bemandawes" instead of unknown user "beman_dawes" </p> Ticket Beman Dawes Sun, 29 Jun 2008 21:21:13 GMT status, resolution, description changed https://svn.boost.org/trac10/ticket/752#comment:2 https://svn.boost.org/trac10/ticket/752#comment:2 <ul> <li><strong>status</strong> <span class="trac-field-old">new</span> → <span class="trac-field-new">closed</span> </li> <li><strong>resolution</strong> <span class="trac-field-old">None</span> → <span class="trac-field-new">invalid</span> </li> <li><strong>description</strong> modified (<a href="/trac10/ticket/752?action=diff&amp;version=2">diff</a>) </li> </ul> <p> Can't diagnose without more information. What was in the try block? Was it supposed to throw or not? Etc. </p> <p> --Beman </p> Ticket