Re: [PATCHES] [HACKERS] PGPASSWORD and client tools

2005-06-09 Thread Bruce Momjian
Tom Lane wrote: > Bruce Momjian writes: > > charpgpassfile[MAXPGPATH]; > > > ! if (!pgpassfile) > > ! { > > ! fprintf(stderr, libpq_gettext("out of memory\n")); > > ! return NULL; > > ! } > > Waste of code, eh? Ne

Re: [PATCHES] [HACKERS] PGPASSWORD and client tools

2005-06-09 Thread Tom Lane
Bruce Momjian writes: > charpgpassfile[MAXPGPATH]; > ! if (!pgpassfile) > ! { > ! fprintf(stderr, libpq_gettext("out of memory\n")); > ! return NULL; > ! } Waste of code, eh? re

Re: [PATCHES] [HACKERS] PGPASSWORD and client tools

2005-06-09 Thread Bruce Momjian
I have applied this patch, but restructured it to better work in our code. Patch attached. I also added documentation. Another new addition is that we now will check to see that the password file is a regular file and not a symlink or something. This was part of your patch for PGPASSFILE but I

Re: [PATCHES] [HACKERS] PGPASSWORD and client tools

2005-06-04 Thread Bruce Momjian
I will add documentation for it. Your patch has been added to the PostgreSQL unapplied patches list at: http://momjian.postgresql.org/cgi-bin/pgpatches It will be applied as soon as one of the PostgreSQL committers reviews and approves it. --

Re: [PATCHES] [HACKERS] PGPASSWORD and client tools

2004-10-12 Thread Bruce Momjian
This has been saved for the 8.1 release: http:/momjian.postgresql.org/cgi-bin/pgpatches2 --- Andrew Dunstan wrote: > > Here's a patch that I think (hope) does this right, by using the file > pointed to by the envi

Re: [PATCHES] [HACKERS] PGPASSWORD and client tools

2004-10-05 Thread Andrew Dunstan
Here's a patch that I think (hope) does this right, by using the file pointed to by the environment var PGPASSFILE, if set, in preference to $HOME/.pgpass. I assume that at this stage it would be held over for 8.1 as a new feature - if not I'll put together some docco in a hurry. cheers andrew