comparison packages/language/cxx/ustl/current/src/uexception.cpp @ 2910:9e1cb7863bef

* src/bktrace.cpp: prevent inclusion of host header <execinfo.h> (eCos builds for Linux synthetic target). * src/uexception.cpp:exception::read(): initialise local variable stmSize.
author jld
date Mon, 24 Aug 2009 06:46:33 +0000
parents 88af52c64ce4
children 4885e0722884
comparison
equal deleted inserted replaced
2909:3e777a018dc7 2910:9e1cb7863bef
33 } 33 }
34 34
35 /// Reads the exception from stream \p is. 35 /// Reads the exception from stream \p is.
36 void exception::read (istream& is) 36 void exception::read (istream& is)
37 { 37 {
38 uint32_t stmSize; 38 uint32_t stmSize = 0;
39 xfmt_t fmt = xfmt_Exception; 39 xfmt_t fmt = xfmt_Exception;
40 is >> fmt >> stmSize >> m_Backtrace; 40 is >> fmt >> stmSize >> m_Backtrace;
41 assert (fmt == m_Format && "The saved exception is of a different type."); 41 assert (fmt == m_Format && "The saved exception is of a different type.");
42 assert ((stmSize + 8) - exception::stream_size() <= is.remaining() && "The saved exception data is corrupt."); 42 assert ((stmSize + 8) - exception::stream_size() <= is.remaining() && "The saved exception data is corrupt.");
43 m_Format = fmt; 43 m_Format = fmt;