id,summary,reporter,owner,description,type,status,milestone,component,version,severity,resolution,keywords,cc 10450,Undefined behavior in boost::filesystem::detail::directory_iterator_construct,egrindha@…,Beman Dawes,"boost/libs/filesystem/src/operations.cpp:2178:28: runtime error: reference binding to null pointer of type 'struct error_code' The problem is this line: it.increment(*ec); ec is 0 when directory_iterator_construct is called from operations.hpp:793 {{{ explicit directory_iterator(const path& p) : m_imp(new detail::dir_itr_imp) { detail::directory_iterator_construct(*this, p, 0); } }}} {{{ [...undefined behavior sanitiser noise...] #3 0x00005555566e623c in boost::filesystem::detail::directory_iterator_construct (it=..., p=..., ec=ec@entry=0x0) at functional/boost/libs/filesystem/src/operations.cpp:2178 #4 0x00005555566b3cfe in directory_iterator (p=..., this=0x7fffffffd7e0) at functional/boost/boost/filesystem/operations.hpp:793 #5 recursive_directory_iterator (opt=boost::filesystem::none, dir_path=..., this=0x7fffffffd760) at functional/boost/boost/filesystem/operations.hpp:1037 [...my code...] }}}",Bugs,new,To Be Determined,filesystem,Boost 1.56.0,Problem,,,