id,summary,reporter,owner,description,type,status,milestone,component,version,severity,resolution,keywords,cc 689,[program_options] Endless loop with long default arguments,ensc,Vladimir Prus,"{{{ when using a po::value with a representation of the default value having a certain length, 'std::cout << opts' will stuck in an endless loop. E.g. ----- #include #include #include namespace po = boost::program_options; int main(int argc, char *argv[]) { po::options_description opts; opts.add_options() (""cfgfile,c"", po::value()->default_value(""/usr/local/etc/myprogramXXXXXXXXX/configuration.conf""), ""the configfile""); std::cout << opts; } ----- | $ rpm -q boost | boost-1.33.1-5 | | $ g++ foo.c -lboost_program_options | $ strace ./a.out | ... | write(1, "" -c [ --cfgfile ] arg (=/usr/lo""..., 80 -c [ --cfgfile ] arg (=/usr/local/etc/myprogramXXXXXXXXX/configuration.conf) | ) = 80 | write(1, "" ""..., 80 | ) = 80 | write(1, "" ""..., 80 | ) = 80 | ... Removing one 'X' will result in an ugly | -c [ --cfgfile ] arg (=/usr/local/etc/myprogramXXXXXXXX/configuration.conf) t | h | e | c | o | n | f | i | g | f | i | l | e output. It would be nice, when: - the default value could be moved into the description column - the description would begin on a new line and an earlier column (e.g. 30-40) when option name/default-value are too long (> 30-40 chars) }}}",Bugs,closed,Boost 1.42.0,program_options,None,Problem,fixed,,s.ochsenknecht@…