Re: [PATCHES] Czech NLS

2003-07-23 Thread Karel Zak
On Wed, Jul 23, 2003 at 11:48:19AM +0200, Peter Eisentraut wrote:
 Karel Zak writes:
 
   the patch contains complete messages transaltion of:
 
 Installed.  Nice work.

 Thanks. What time will freeze backend messages? I think after beta
 release.

Karel

-- 
 Karel Zak  [EMAIL PROTECTED]
 http://home.zf.jcu.cz/~zakkr/

---(end of broadcast)---
TIP 7: don't forget to increase your free space map settings


Re: [PATCHES] Czech NLS

2003-07-23 Thread Peter Eisentraut
Karel Zak writes:

  the patch contains complete messages transaltion of:

Installed.  Nice work.

-- 
Peter Eisentraut   [EMAIL PROTECTED]

---(end of broadcast)---
TIP 6: Have you searched our list archives?

   http://archives.postgresql.org


Re: [PATCHES] PG Patch (fwd) [openserver patch followup #2]

2003-07-23 Thread Peter Eisentraut
Larry Rosenman writes:

 Why do this at all? Security. Having shared libraries without full SONAME's
 is a big security risk. There have been any number of huge explots based
 around this. Point me at any Solaris machine = 2.7, or any OSR5 system 
 507 or any FreeBSD system = 4.0 and I can get root with 1 tiny program
 thats on all of them: xterm. It has long upset me, and I am done trying to
 convince them, but libtool encourages the worst possible .so practices, and
 may programs seem to have picked up those equally bad practices. There is
 no need for futzing with ld.conf and the like if people take the time to
 construct shared libraries propperly. Yes it can be a pain to bootstrap but
 the reward is very well worth the effort it takes.

These concerns might have some merit, but the solution could not possibly
be to only fix this on one platform, because the mechanisms are the same
everywhere.  That said, it seems the universal practice is not to put full
sonames into shared libraries, so it seems better that our libraries
follow that practice.  Otherwise it will be only a matter of time before
someone comes out of the wood and claims that libraries will full sonames
are a big whatever-else problem.

-- 
Peter Eisentraut   [EMAIL PROTECTED]

---(end of broadcast)---
TIP 9: the planner will ignore your desire to choose an index scan if your
  joining column's datatypes do not match


Re: [PATCHES] PG Patch (fwd) [openserver patch followup #2]

2003-07-23 Thread Larry Rosenman


--On Wednesday, July 23, 2003 12:20:34 +0200 Peter Eisentraut 
[EMAIL PROTECTED] wrote:

Larry Rosenman writes:

Why do this at all? Security. Having shared libraries without full
SONAME's is a big security risk. There have been any number of huge
explots based around this. Point me at any Solaris machine = 2.7, or
any OSR5 system  507 or any FreeBSD system = 4.0 and I can get root
with 1 tiny program thats on all of them: xterm. It has long upset me,
and I am done trying to convince them, but libtool encourages the worst
possible .so practices, and may programs seem to have picked up those
equally bad practices. There is no need for futzing with ld.conf and the
like if people take the time to construct shared libraries propperly.
Yes it can be a pain to bootstrap but the reward is very well worth the
effort it takes.
These concerns might have some merit, but the solution could not possibly
be to only fix this on one platform, because the mechanisms are the same
everywhere.  That said, it seems the universal practice is not to put full
sonames into shared libraries, so it seems better that our libraries
follow that practice.  Otherwise it will be only a matter of time before
someone comes out of the wood and claims that libraries will full sonames
are a big whatever-else problem.
Universal Practice does NOT equal Security and Usability.

Please consider what Kean is saying here.

Kean,
   Please respond.
LER



--
Larry Rosenman http://www.lerctr.org/~ler
Phone: +1 972-414-9812 E-Mail: [EMAIL PROTECTED]
US Mail: 1905 Steamboat Springs Drive, Garland, TX 75044-6749
---(end of broadcast)---
TIP 1: subscribe and unsubscribe commands go to [EMAIL PROTECTED]


[PATCHES] patch for compile warning on date.c

2003-07-23 Thread Joe Conway
I just noticed a new compile warning on date.c. Attached patch fixes it.

Joe
Index: src/backend/utils/adt/date.c
===
RCS file: /opt/src/cvs/pgsql-server/src/backend/utils/adt/date.c,v
retrieving revision 1.85
diff -c -r1.85 date.c
*** src/backend/utils/adt/date.c24 Jul 2003 00:21:26 -  1.85
--- src/backend/utils/adt/date.c24 Jul 2003 04:10:32 -
***
*** 350,356 
DateADT result;
struct tm   tt,
   *tm = tt;
!   double  fsec;
  
if (TIMESTAMP_NOT_FINITE(timestamp))
PG_RETURN_NULL();
--- 350,356 
DateADT result;
struct tm   tt,
   *tm = tt;
!   fsec_t  fsec;
  
if (TIMESTAMP_NOT_FINITE(timestamp))
PG_RETURN_NULL();

---(end of broadcast)---
TIP 7: don't forget to increase your free space map settings


Re: [HACKERS] [PATCHES] PATCH: Memory leaks on start-up

2003-07-23 Thread Bruce Momjian

Your patch has been added to the PostgreSQL unapplied patches list at:

http://momjian.postgresql.org/cgi-bin/pgpatches

I will try to apply it within the next 48 hours.

---


Lee Kindness wrote:
Content-Description: message body text

 Tom, happier with the attached patch?
 
 I'd have to disagree with regards to the memory leaks not being worth
 a mention - any such leak can cause problems when the PostgreSQL
 installation is either unattended, long-living andor has very high
 connection levels. Half a kilobyte on start-up isn't negligible in
 this light.
 
 Regards, Lee.
 
 Tom Lane writes:
   Lee Kindness [EMAIL PROTECTED] writes:
Guys, attached is a patch to fix two memory leaks on start-up.
   
   I do not like the changes to miscinit.c.  In the first place, it is not
   a memory leak to do a one-time allocation of state for a proc_exit
   function.  A bigger complaint is that your proposed change introduces
   fragile coupling between CreateLockFile and its callers, in order to
   save no resources worth mentioning.  More, it introduces an assumption
   that the globals directoryLockFile and socketLockFile don't change while
   the postmaster is running.  UnlinkLockFile should unlink the file that
   it was originally told to unlink, regardless of what happens to those
   globals.
   
   If you are intent on spending code to free stuff just before the
   postmaster exits, a better fix would be for UnlinkLockFile to free its
   string argument after using it.
 

 Index: src/backend/libpq/pqcomm.c
 ===
 RCS file: /projects/cvsroot/pgsql-server/src/backend/libpq/pqcomm.c,v
 retrieving revision 1.157
 diff -u -r1.157 pqcomm.c
 --- src/backend/libpq/pqcomm.c12 Jun 2003 07:36:51 -  1.157
 +++ src/backend/libpq/pqcomm.c22 Jul 2003 14:16:46 -
 @@ -363,7 +363,7 @@
   added++;
   }
  
 - freeaddrinfo(addrs);
 + freeaddrinfo2(family, addrs);
  
   if (!added)
   {
 Index: src/backend/utils/init/miscinit.c
 ===
 RCS file: /projects/cvsroot/pgsql-server/src/backend/utils/init/miscinit.c,v
 retrieving revision 1.104
 diff -u -r1.104 miscinit.c
 --- src/backend/utils/init/miscinit.c 27 Jun 2003 19:08:37 -  1.104
 +++ src/backend/utils/init/miscinit.c 22 Jul 2003 14:16:46 -
 @@ -673,8 +673,15 @@
  static void
  UnlinkLockFile(int status, Datum filename)
  {
 - unlink((char *) DatumGetPointer(filename));
 - /* Should we complain if the unlink fails? */
 +  char *fname = (char *)DatumGetPointer(filename);
 +  if( fname != NULL )
 +{
 +  if( unlink(fname) != 0 )
 + {
 +   /* Should we complain if the unlink fails? */
 + }
 +  free(fname);
 +}
  }
  
  /*

 
 ---(end of broadcast)---
 TIP 1: subscribe and unsubscribe commands go to [EMAIL PROTECTED]

-- 
  Bruce Momjian|  http://candle.pha.pa.us
  [EMAIL PROTECTED]   |  (610) 359-1001
  +  If your life is a hard drive, |  13 Roberts Road
  +  Christ can be your backup.|  Newtown Square, Pennsylvania 19073

---(end of broadcast)---
TIP 9: the planner will ignore your desire to choose an index scan if your
  joining column's datatypes do not match