List:MySQL++« Previous MessageNext Message »
From:Chris Frey Date:February 19 2005 9:32pm
Subject:Re: Can connect but get seg fault as soon as i try to get a Result Set
View as plain text  
On Sat, Feb 19, 2005 at 02:42:08PM -0500, Chris Gagnon wrote:
> Hi i can get the program to connect to the database but as soon as i
> attempt to retrieve a result set it Seg Faults and i can't figure out
> why. As you can see i've added extra catch( ...)'s to ensure i'm not
> missing any exceptions.

Please post a backtrace of the segfault.

> Here is the code:
>   
>   //declaired private in the class containing this code block
>   Connection *dbCon;
> 
>   //initialize database
>   try
>   {
>      dbCon = new Connection(use_exceptions);

This is unrelated, but you don't have to allocate this on the heap.
Allocating on the heap without at least using auto_ptr<> means there
can be memory leaks when exceptions happen.

- Chris

Thread
Can connect but get seg fault as soon as i try to get a Result SetChris Gagnon19 Feb
  • Re: Can connect but get seg fault as soon as i try to get a Result SetChris Frey19 Feb
  • Re: Can connect but get seg fault as soon as i try to get a ResultSetWarren Young21 Feb
RE: Can connect but get seg fault as soon as i try to get a Result Setdienw21 Feb