You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'am writing a RTSP1.0 parser with Qi, so I created a grammar for response message types and one for request message types. All worked perfectly so far, unit tested them, using no state or semantic actions but the attributed types struct bindings. Now I just wanted to combine them as a simple alternative into a boost::variant. (see https://github.com/Superlokkus/boost_spirit_bug/blob/parser_vtable_bad_access_minimal_example/src/streaming_lib/include/rtsp_message.hpp#L142 )
(so that I can just parse in general rtsp messages, which is need for rtsp clients since they could also get request from the server, and so messages are even rfc defined as the alternative)
But this simple grammar which combines the mentioned grammars, explodes with segmentation faults/memory access violation: invalid permissions in boost::function4 with fusion while parsing.
I tested it with boost 1.66 Apple LLVM version 10.0.0 (clang-1000.11.45.2) on a mac host and with boost 1.69 gcc (SUSE Linux) 7.3.1 20180323 [gcc-7-branch revision 258812] on a suse x86-64 host.
I would paste a wandbox link, but boost::test or boost::spirit needs to much ram for compiling and quits because of this. Find a stack trace attached if you can not clone and execute it yourself.
I can try to make the example more minimal, but I hope since the grammars don't have custom side effects and valid grammars, that you can already use it.
Hi,
I'am writing a RTSP1.0 parser with Qi, so I created a grammar for response message types and one for request message types. All worked perfectly so far, unit tested them, using no state or semantic actions but the attributed types struct bindings. Now I just wanted to combine them as a simple alternative into a boost::variant. (see https://github.com/Superlokkus/boost_spirit_bug/blob/parser_vtable_bad_access_minimal_example/src/streaming_lib/include/rtsp_message.hpp#L142 )
(so that I can just parse in general rtsp messages, which is need for rtsp clients since they could also get request from the server, and so messages are even rfc defined as the alternative)
But this simple grammar which combines the mentioned grammars, explodes with segmentation faults/memory access violation: invalid permissions in
boost::function4
withfusion
while parsing.I tested it with boost 1.66 Apple LLVM version 10.0.0 (clang-1000.11.45.2) on a mac host and with boost 1.69 gcc (SUSE Linux) 7.3.1 20180323 [gcc-7-branch revision 258812] on a suse x86-64 host.
I would paste a wandbox link, but boost::test or boost::spirit needs to much ram for compiling and quits because of this. Find a stack trace attached if you can not clone and execute it yourself.
I can try to make the example more minimal, but I hope since the grammars don't have custom side effects and valid grammars, that you can already use it.
Code/Repo: https://github.com/Superlokkus/boost_spirit_bug
boost_spirt_stack.txt
The text was updated successfully, but these errors were encountered: