title: c++ -std=c++0x cause segmentation fault (boost logging)
body: <p>i copied a program from <a href="https://github.com/boostorg/log/blob/master/example/basic_usage/main.cpp" rel="nofollow">https://github.com/boostorg/log/blob/master/example/basic_usage/main.cpp</a>. i renamed the main.cpp to mylog.cpp. at beggining I compiled it with -std=c++0x (detail is showed below). it was built fine but got segmentation fault when i run the executable file.  without -std=c++0x, program is running fine. pleae help. I am really new to c++, therefore, i may miss some debug information. let me know if there is any information you need to debug this problem. Thanks</p>
  
  <p>note: i uncommented first three lines on this main.cpp</p>
  
  <pre><code>#define BOOST_LOG_USE_CHAR
  #define BOOST_ALL_DYN_LINK 1
  #define BOOST_LOG_DYN_LINK 1
  </code></pre>
  
  <p>build settings from eclipse(in order to build this program, i think boost log library is needed):</p>
  
  <pre><code>make all 
  Building file: ../mylog.cpp
  Invoking: GCC C++ Compiler
  g++ -I/home/help/usr/local/boost_1_54_0 -O0 -g3 -Wall -c -fmessage-length=0 -std=c++0x -MMD -MP -MF"mylog.d" -MT"mylog.d" -o "mylog.o" "../mylog.cpp"
  Finished building: ../mylog.cpp
  
  Building target: test
  Invoking: GCC C++ Linker
  g++ -L/home/help/usr/local/lib -o "test"  ./mylog.o   -lpthread -lboost_thread -lboost_system -lboost_log_setup -lboost_log
  Finished building target: test
  </code></pre>
  
  <p>after built, I run this program and got segmentation fault.</p>
  
  <pre><code>$ ./mylog
  Segmentation fault (core dumped)
  </code></pre>
  
  <p>use gdb. it points me to a library</p>
  
  <pre><code>Program received signal SIGSEGV, Segmentation fault.
  0x00007ffff7100c0a in boost::log::v2_mt_posix::attribute_value_set::find(boost::log::v2_mt_posix::attribute_name) const () from /home/fcai/usr/local/lib/libboost_log.so.1.54.0
  (gdb) list
  73      return strm;
  74  }
  75  
  76  int main(int argc, char* argv[])
  77  {
  78      // This is a simple tutorial/example of Boost.Log usage
  79  
  80      // The first thing we have to do to get using the library is
  81      // to set up the logging sinks - i.e. where the logs will be written to.
  82      logging::add_console_log(std::clog, keywords::format = "%TimeStamp%: %Message%");
  (gdb) bt
  #0  0x00007ffff7100c0a in boost::log::v2_mt_posix::attribute_value_set::find(boost::log::v2_mt_posix::attribute_name) const () from /home/fcai/usr/local/lib/libboost_log.so.1.54.0
  #1  0x000000000042713f in boost::log::v2_mt_posix::value_extractor&lt;boost::mpl::vector2&lt;std::string, std::basic_string&lt;wchar_t, std::char_traits&lt;wchar_t&gt;, std::allocator&lt;wchar_t&gt; &gt; &gt;, boost::log::v2_mt_posix::fallback_to_none, boost::log::v2_mt_posix::expressions::tag::message&gt;::operator() (this=0x7fffffffc6b0, name=..., attrs=...) at /home/fcai/usr/local/boost_1_54_0/boost/log/attributes/value_extraction.hpp:232
  #2  0x00007ffff74c379d in boost::log::v2_mt_posix::aux::light_function&lt;void (boost::log::v2_mt_posix::record_view const&amp;, boost::log::v2_mt_posix::basic_formatting_ostream&lt;char, std::char_traits&lt;char&gt;, std::allocator&lt;char&gt; &gt;&amp;)&gt;::impl&lt;boost::log::v2_mt_posix::(anonymous namespace)::chained_formatter&lt;char, boost::phoenix::actor&lt;boost::proto::exprns_::expr&lt;boost::proto::tagns_::tag::shift_left, boost::proto::argsns_::list2&lt;boost::phoenix::actor&lt;boost::proto::exprns_::basic_expr&lt;boost::proto::tagns_::tag::terminal, boost::proto::argsns_::term&lt;boost::phoenix::argument&lt;2&gt; &gt;, 0l&gt; &gt;, boost::log::v2_mt_posix::expressions::attribute_actor&lt;boost::mpl::vector2&lt;std::string, std::basic_string&lt;wchar_t, std::char_traits&lt;wchar_t&gt;, std::allocator&lt;wchar_t&gt; &gt; &gt;, boost::log::v2_mt_posix::fallback_to_none, boost::log::v2_mt_posix::expressions::tag::message, boost::phoenix::actor&gt; &gt;, 2l&gt; &gt; &gt; &gt;::invoke_impl(boost::log::v2_mt_posix::aux::light_function&lt;void (boost::log::v2_mt_posix::record_view const&amp;, boost::log::v2_mt_posix::basic_formatting_ostream&lt;char, std::char_traits&lt;char&gt;, std::allocator&lt;char&gt; &gt;&amp;)&gt;::impl_base*, boost::log::v2_mt_posix::record_view const&amp;, boost::log::v2_mt_posix::basic_formatting_ostream&lt;char, std::char_traits&lt;char&gt;, std::allocator&lt;char&gt; &gt;&amp;) () from /home/fcai/usr/local/lib/libboost_log_setup.so.1.54.0
  #3  0x0000000000431b64 in boost::log::v2_mt_posix::aux::light_function&lt;void (boost::log::v2_mt_posix::record_view const&amp;, boost::log::v2_mt_posix::basic_formatting_ostream&lt;char, std::char_traits&lt;char&gt;, std::allocator&lt;char&gt; &gt;&amp;)&gt;::operator()(boost::log::v2_mt_posix::record_view const&amp;, boost::log::v2_mt_posix::basic_formatting_ostream&lt;char, std::char_traits&lt;char&gt;, std::allocator&lt;char&gt; &gt;&amp;) const (this=0x652ab8, 
      args#0=..., args#1=...) at /home/fcai/usr/local/boost_1_54_0/boost/log/detail/light_function.hpp:444
  #4  0x00000000004306db in boost::log::v2_mt_posix::basic_formatter&lt;char&gt;::operator() (this=0x652ab8, rec=..., strm=...) at /home/fcai/usr/local/boost_1_54_0/boost/log/expressions/formatter.hpp:157
  #5  0x0000000000430806 in boost::log::v2_mt_posix::sinks::basic_formatting_sink_frontend&lt;char&gt;::feed_record&lt;boost::log::v2_mt_posix::aux::fake_mutex, boost::log::v2_mt_posix::sinks::basic_text_ostream_backend&lt;char&gt; &gt; (this=0x6507c0, rec=..., backend_mutex=..., backend=...) at /home/fcai/usr/local/boost_1_54_0/boost/log/sinks/basic_sink_frontend.hpp:440
  #6  0x000000000042f505 in boost::log::v2_mt_posix::sinks::basic_formatting_sink_frontend&lt;char&gt;::try_feed_record&lt;boost::mutex, boost::log::v2_mt_posix::sinks::basic_text_ostream_backend&lt;char&gt; &gt; (this=0x6507c0, 
      rec=..., backend_mutex=..., backend=...) at /home/fcai/usr/local/boost_1_54_0/boost/log/sinks/basic_sink_frontend.hpp:489
  #7  0x000000000042d28e in boost::log::v2_mt_posix::sinks::synchronous_sink&lt;boost::log::v2_mt_posix::sinks::basic_text_ostream_backend&lt;char&gt; &gt;::try_consume (this=0x6507c0, rec=...)
      at /home/fcai/usr/local/boost_1_54_0/boost/log/sinks/sync_frontend.hpp:145
  #8  0x00007ffff7106053 in boost::log::v2_mt_posix::core::push_record_move(boost::log::v2_mt_posix::record&amp;) () from /home/fcai/usr/local/lib/libboost_log.so.1.54.0
  #9  0x000000000041f8f1 in push_record (rec=..., this=0x651050) at /home/fcai/usr/local/boost_1_54_0/boost/log/core/core.hpp:308
  #10 boost::log::v2_mt_posix::sources::basic_logger&lt;char, boost::log::v2_mt_posix::sources::logger, boost::log::v2_mt_posix::sources::single_thread_model&gt;::push_record_unlocked(boost::log::v2_mt_posix::record&amp;&amp;) (this=0x7fffffffccc0, rec=...) at /home/fcai/usr/local/boost_1_54_0/boost/log/sources/basic_logger.hpp:268
  #11 0x000000000041d2e6 in boost::log::v2_mt_posix::sources::basic_composite_logger&lt;char, boost::log::v2_mt_posix::sources::logger, boost::log::v2_mt_posix::sources::single_thread_model, boost::log::v2_mt_posix::sources::features&lt;&gt; &gt;::push_record(boost::log::v2_mt_posix::record&amp;&amp;) (this=0x7fffffffccc0, rec=...) at /home/fcai/usr/local/boost_1_54_0/boost/log/sources/basic_logger.hpp:582
  #12 0x000000000041a9b4 in boost::log::v2_mt_posix::aux::record_pump&lt;boost::log::v2_mt_posix::sources::logger&gt;::~record_pump (this=0x7fffffffd170, __in_chrg=&lt;optimized out&gt;)
      at /home/fcai/usr/local/boost_1_54_0/boost/log/sources/record_ostream.hpp:279
  #13 0x0000000000414de3 in main (argc=1, argv=0x7fffffffd7b8) at ../mylog.cpp:116
  (gdb) 
  </code></pre>