Hi John, I cannot reproduce the problem in a sample program (yet). The symptions appear to be stack corruption. In the function template <class charT> w32_regex_traits_char_layer<charT>::w32_regex_traits_char_layer(::boost::re_detail::lcid_type l) : w32_regex_traits_base<charT>(l) { line 187: w32_regex_traits.hpp the line std::string cat_name(w32_regex_traits<charT>::get_catalog_name()); executes ok, looking at the debugger, _Mysize = 0 , _Myres = 15 which is expected. Then stepping into if(cat_name.size()) inside the call, _mysize is now equal to some crazy number. The interesting point is that the debugger steps to the line return (_Mysize); and bypasses the line above being { // return length of sequence In the sample program, the debugger always steps onto the { line, then the return line. So at this point, something has lost the plot. To try to narrow down the problem, I put the call to the wregex as the first lines in the program. In theory, no corruption of any memory should have occured during void __cdecl _initterm ( initialisation. As a test, I am downloading another regular expression class to see what happens. I have run with Compuware Bounds Checker, and every other trick I know, and there just does not seem to be any memory corruption, dangling pointers or anything. It's driving me mad, but I realise without a sample program showing the problem, neither can you. Regards, Alan
From: "John Maddock"
Reply-To: boost-users@lists.boost.org To: Subject: Re: [Boost-users] Regex crash Date: Wed, 9 Aug 2006 17:08:32 +0100 Alan Gray wrote:
Hi all,
Has anyone had troubles with using wregex? regex works fine for me. Here is the stack dump.
Dangling pointer maybe? Otherwise please try and produce a test case.
Many thanks, John. _______________________________________________ Boost-users mailing list Boost-users@lists.boost.org http://lists.boost.org/mailman/listinfo.cgi/boost-users