List:MySQL++« Previous MessageNext Message »
From:aberger@agsense.net Date:May 3 2007 7:50pm
Subject:query memory bug
View as plain text  
I am using mysql++-2.2.3 on freeBSD 6.1 with mysql 4.1.22

Currently I have a structuer of data that I form into a query and then 
store it in the db.

if I print out the structure before I create the query object, the 
structure looks fine. When i print out the structure after the query 
object a small section of the data in the structure is corrupt. If I 
remove the mysql++ calls from the function the struct remains fine.

Here is an example of the code

        for(int i = 0; i < 64; i++) {
          printf("%3d: %d, %d\t", b3->t0[i].sen, b3->t0[i].stat, 
b3->t0[i].read);
          if(i % 4 == 3)
            puts("");
        }puts("Next1");

  //create our query

query = new Query(connection.query()); //this is cuasing the problem

        for(int i = 0; i < 64; i++) {
          printf("%3d: %d, %d\t", b3->t0[i].sen, b3->t0[i].stat, 
b3->t0[i].read);
          if(i % 4 == 3)
            puts("");
        }puts("Next2");

I'll gladly supply any more code/information if needed

Aaron
Thread
query memory bugaberger@agsense.net3 May
  • Re: query memory bugWarren Young3 May
    • Re: query memory bugaberger@agsense.net4 May