PATCH for pgconnection.h

From: Brian P Millett <bpm(at)ec-group(dot)com>
To: postgres <hackers(at)postgreSQL(dot)org>
Subject: PATCH for pgconnection.h
Date: 1999-06-24 16:23:32
Message-ID: 37725B83.763194EC@ec-group.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

I am using the Sun Workshop C 5.0, noticed that I was getting the
following errors:
"pgconnection.h", line 65: Error: string is not defined.
"pgconnection.cc", line 134: Error: string is not defined.
"pgconnection.cc", line 139: Error: Cannot return char* from a function
that should return int.
3 Error(s) detected.

Futher looking noticed that the standard namespace was not being used
for the "string" typedef, so the following patch fixed that for me.
This is for the 6.5 tar release & the 6/24 CVS checkout.

vlad: diff -w3c interfaces/libpq++/pgconnection.h.orig
interfaces/libpq++/pgconnection.h
*** interfaces/libpq++/pgconnection.h.orig Thu Jun 24 10:49:54 1999

--- interfaces/libpq++/pgconnection.h Thu Jun 24 10:48:31 1999
***************
*** 23,28 ****
--- 23,34 ----
#include <stdio.h>
#include <string>

+ #ifdef __sun__
+ #ifndef __GNUC__
+ using namespace std;
+ #endif
+ #endif
+
extern "C" {
#include "libpq-fe.h"
}

--
Brian Millett
Enterprise Consulting Group "Heaven can not exist,
(314) 205-9030 If the family is not eternal"
bpm(at)ec-group(dot)com F. Ballard Washburn

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Don Baccus 1999-06-24 18:59:17 fsynch of pg_log write..
Previous Message Thomas Lockhart 1999-06-24 16:04:11 Re: [HACKERS] Re: [PORTS] Postgres on NT freezing