Re[4]: [HACKERS] Re: [QUESTIONS] libpq++ - Mailing list pgsql-hackers

From Leo Shuster
Subject Re[4]: [HACKERS] Re: [QUESTIONS] libpq++
Date
Msg-id b1cff487d7dba1203c1ef6ab9713f3b4
Whole thread Raw
List pgsql-hackers
>My program crash with core dump if compiled without "-fexternal-templates"
>But it happens only when PgEnv used like
>PgEnv env("",host_name,...
>that is with explicit constructor.
    Strange indeed.  GNU's implementation of string class is not
    the greatest and it tends to crash in the most unexpected
    situations.  There are some tricks, however, you can use
    to prevent that.  I'll double-check the code and see if
    there anything can be done to prevent the crashes.

>In my distribution (postgresql-6.1.tar.gz) src/libpq++/example/* are not ever
>contain PgEnv word. But I indeed need of PgEnv(...) because it is more
>suitable than dinamical changing environment on various hosts
    I'll check the examples.  Basically, there is not much to the PgEnv's
    usage: it is simply a storage class for the Postgres environment.
    It stores either default parameters or whatever you send to it.
    There is just the constructor call and that's it.  All the other
    methods are simply accessors.

>May be there are some special tricks when gdb is used for templates
>classes calls tracing?
    I am not aware of any.  I can't consider myself an expert on gdb,
    so if anyone has some hints, I'll gladly listen to them.

Leo

------------------------------

pgsql-hackers by date:

Previous
From: Bruce Momjian
Date:
Subject: [HACKERS] [BUGS] DateStyle (fwd)
Next
From: John Robinson
Date:
Subject: [HACKERS] Case sensitivity in identifiers