Boost C++ Libraries: Ticket #8681: read_graphviz throws exception with file that dot program reads successfully https://svn.boost.org/trac10/ticket/8681 <p> program exhibiting behavior attached as boost-test.cpp. compiled on g++ (Debian 4.7.2-5) 4.7.2. </p> <p> compile with "g++ -Wall -std=c++11 -O2 -lboost_system -lboost_graph -o boost-test boost-test.cpp" </p> <p> dot file attached as test.dot, and pasted below: digraph "flow_graph" { </p> <blockquote> <p> graph [ ]; node [ </p> <blockquote> <p> shape = "box" </p> </blockquote> <p> ]; edge [ ]; "0" [ </p> <blockquote> <p> label = "_WinMainCRTStartup:\lpush ebp\lmov ebp, esp\lsub esp, 18h\land esp, 0FFFFFFF0h\lmov [esp+18h+var_18], offset _main\lcall _cygwin_crt0\lmov [esp+18h+var_10], 0\lmov [esp+18h+var_14], 0\lmov [esp+18h+var_18], 0\lcall _cygwin_premain0\lmov [esp+18h+var_10], 0\lmov [esp+18h+var_14], 0\lmov [esp+18h+var_18], 0\lcall _cygwin_premain1\lmov [esp+18h+var_10], 0\lmov [esp+18h+var_14], 0\lmov [esp+18h+var_18], 0\lcall _cygwin_premain2\lmov [esp+18h+var_10], 0\lmov [esp+18h+var_14], 0\lmov [esp+18h+var_18], 0\lcall _cygwin_premain3\lleave\lretn\l" </p> </blockquote> <p> ]; </p> </blockquote> <p> <em> node 0 } </em></p> en-us Boost C++ Libraries /htdocs/site/boost.png https://svn.boost.org/trac10/ticket/8681 Trac 1.4.3 anonymous Mon, 10 Jun 2013 01:27:41 GMT attachment set https://svn.boost.org/trac10/ticket/8681 https://svn.boost.org/trac10/ticket/8681 <ul> <li><strong>attachment</strong> → <span class="trac-field-new">boost-test.cpp</span> </li> </ul> Ticket anonymous Mon, 10 Jun 2013 01:28:00 GMT attachment set https://svn.boost.org/trac10/ticket/8681 https://svn.boost.org/trac10/ticket/8681 <ul> <li><strong>attachment</strong> → <span class="trac-field-new">test.dot</span> </li> </ul> <p> dot file which yields exception </p> Ticket anonymous Mon, 10 Jun 2013 01:30:32 GMT <link>https://svn.boost.org/trac10/ticket/8681#comment:1 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/8681#comment:1</guid> <description> <p> exception message is: </p> <p> Invalid start token for statement (token is "&lt;eof&gt; <em>") </em></p> </description> <category>Ticket</category> </item> <item> <dc:creator>anonymous</dc:creator> <pubDate>Mon, 10 Jun 2013 01:39:11 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/8681#comment:2 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/8681#comment:2</guid> <description> <p> the comment at boost-test.cpp:5 is incorrect- test_dot was not null-terminated. (std::string was constructed from it using begin and end iterators). </p> </description> <category>Ticket</category> </item> <item> <dc:creator>anonymous</dc:creator> <pubDate>Mon, 10 Jun 2013 03:02:06 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/8681#comment:3 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/8681#comment:3</guid> <description> <p> from some experimentation, it appears that deleting line 12 in test.dot (i.e. the line containing a comment) causes the exception to not be thrown from read_graphviz. </p> </description> <category>Ticket</category> </item> <item> <dc:creator>Jeremiah Willcock</dc:creator> <pubDate>Mon, 10 Jun 2013 13:50:27 GMT</pubDate> <title>component changed; owner set https://svn.boost.org/trac10/ticket/8681#comment:4 https://svn.boost.org/trac10/ticket/8681#comment:4 <ul> <li><strong>owner</strong> set to <span class="trac-author">Jeremiah Willcock</span> </li> <li><strong>component</strong> <span class="trac-field-old">None</span> → <span class="trac-field-new">graph</span> </li> </ul> Ticket Jeremiah Willcock Mon, 10 Jun 2013 14:29:40 GMT status changed; resolution set https://svn.boost.org/trac10/ticket/8681#comment:5 https://svn.boost.org/trac10/ticket/8681#comment:5 <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-new">fixed</span> </li> </ul> <p> (In <a class="changeset" href="https://svn.boost.org/trac10/changeset/84725" title="Changed // comments to be non-greedy; fixes #8681">[84725]</a>) Changed <em> comments to be non-greedy; fixes <a class="closed ticket" href="https://svn.boost.org/trac10/ticket/8681" title="#8681: Bugs: read_graphviz throws exception with file that dot program reads ... (closed: fixed)">#8681</a> </em></p> Ticket Jeremiah Willcock Mon, 10 Jun 2013 14:30:40 GMT <link>https://svn.boost.org/trac10/ticket/8681#comment:6 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/8681#comment:6</guid> <description> <p> I fixed that issue. Your code still breaks because you do not define a "shape" property in your <code>dynamic_properties</code> object, but the file appears to parse correctly. </p> </description> <category>Ticket</category> </item> <item> <dc:creator>anonymous</dc:creator> <pubDate>Mon, 10 Jun 2013 14:57:55 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/8681#comment:7 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/8681#comment:7</guid> <description> <p> thank you! </p> </description> <category>Ticket</category> </item> </channel> </rss>