
Will Bryant wrote:
Here's one to produce my segfault, which may or may not be the same as yours:
#include
#include <iostream> int main(int argc, char* argv[]) { try { boost::program_options::options_description desc("Test"); desc.add_options()("test", boost::program_options::valuestd::string(), "import the specified OBJ file and save it to MDLM format"); std::cerr << desc; return 0; } catch (const std::exception& except) { std::cerr << except.what() << std::endl; return 1; } }
As per my message the other day, this triggers a bug in options_description.cpp's format_paragraph function, which causes a segfault on linux with g++ 4.0.2 (and an assertion failure on Visual Studio 2005 beta 2); running it under valgrind 2.4.0 on linux produces:
Can you replace options_description.cpp with http://zigzag.cs.msu.su/~ghost/options_description.cpp And try again. The problem is that I can't reproduce the problem myself, neither with valgrind nor with libstdc++ debug mode, so I rely on users to tell if it's gone. - Volodya