I'm running 5.0.21, so the 5.0.24 problem shouldn't be affecting me. As
for your question about what exception was thrown, how do I find that
out? I tried debugging dbinfo.cpp. It errored trying to execute the
statement cout << "Query: " << query.preview() << endl; The text in the
original message was what VS provided in the error window.
As far as the string code goes, the function is shown below.
if (_State == ios_base::goodbit)
for (_Mysizt _Count = 0; _Count < _Size; ++_Count)
if (_Traits::eq_int_type(_Traits::eof(),
_Ostr.rdbuf()->sputc(_Str[_Count]))) <----- The
instruction pointer in the debug window indicated this line when the
error occurred.
{ // insertion failed, quit
_State |= ios_base::badbit;
break;
}
At the time of the break in execution, _Count was 0, _Size was
0x0000000f, the pointer to _Str was bad.
This bad string pointer appears to be the basis of most of the problems
I am seeing.
Further investigation indicates that the problem is happening when I try
to set up the first actual query. I am assuming that the original query
string is held in the sbuffer_ attribute of the query object. After the
statement:
Query query = con.query(); is executed, this attribute holds a bad
pointer.
I also noticed that the connection information in the conn_attribute
seems to be invalid.
I tried stepping into the function query << "show databases"; I noticed
that it is using ostream calls, not string calls as I would expect.
This function finished with the "show databases" string being pointed to
by _Gfirst, _Pfirst, and _Gnext in the _Mystrbuf structure. The
sbuffer_ attribute (which I would expect to point to the query) still
held a bad pointer.
Is it possible that the query.preview member function is looking in the
wrong place for the string?
Thanks
Gary
Warren Young wrote:
> Gary Anderson wrote:
>
>> Unhandled exception at 0x104f1795 (msvcp80d.dll) in dbinfo.exe:
>> 0xC0000005: Access violation reading location 0x74616420. The code
>> broke in the string library.
>
>
> What exception was thrown?
>
>> Resetdb still errors also: Unhandled exception at 0x7c81eb33 in
>> resetdb.exe: Microsoft C++ exception: std::bad_alloc at memory
>> location 0x0012ebc0.. This one broke in the new function of new.cpp.
>
>
> Someone reported that this sort of thing would happen with the
> brandest newest MySQL. Try rolling back to 5.0.22.
>