Mombu the Programming Forum sponsored links

Go Back   Mombu the Programming Forum > Programming > PATCH: Uninitialized variable usage in contrib/pg_autovacuum
User Name
Password
REGISTER NOW! Mark Forums Read

sponsored links


Reply
 
1 31st May 12:49
craig
External User
 
Posts: 1
Default PATCH: Uninitialized variable usage in contrib/pg_autovacuum


Sorry about the cross-post -- I'm not 100% sure which list this should be sent
to.

I noticed in the 7.4 release that in contrib/pg_autovacuum, args->logfile is
not initialized if a log file is not specified on the command line. This
causes an immediate segfault on systems that fill allocated memory with some
value other than zero (my FreeBSD machine uses 0xD0).

Several crashes later I discovered that args->user, password, host, and port
are also used without being initialized.

This doesn't appear to be fixed in CVS and I came up empty on a mailing list
search -- hope it hasn't been reported already.

Attached is a quick patch that fixes the problem.

--
Craig


---------------------------(end of broadcast)---------------------------
TIP 1: subscribe and unsubscribe commands go to majordomo@postgresql.org
  Reply With Quote


  sponsored links


2 31st May 12:50
craig
External User
 
Posts: 1
Default PATCH: Uninitialized variable usage in contrib/pg_autovacuum


Sorry about the cross-post -- I'm not 100% sure which list this should be sent
to.

I noticed in the 7.4 release that in contrib/pg_autovacuum, args->logfile is
not initialized if a log file is not specified on the command line. This
causes an immediate segfault on systems that fill allocated memory with some
value other than zero (my FreeBSD machine uses 0xD0).

Several crashes later I discovered that args->user, password, host, and port
are also used without being initialized.

This doesn't appear to be fixed in CVS and I came up empty on a mailing list
search -- hope it hasn't been reported already.

Attached is a quick patch that fixes the problem.

--
Craig


---------------------------(end of broadcast)---------------------------
TIP 1: subscribe and unsubscribe commands go to majordomo@postgresql.org
  Reply With Quote


  sponsored links


3 9th June 22:07
pgman
External User
 
Posts: 1
Default PATCH: Uninitialized variable usage in contrib/pg_autovacuum


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.

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


[ Attachment, skipping... ]

--
Bruce Momjian | http://candle.pha.pa.us
pgman@candle.pha.pa.us | (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
  Reply With Quote
Reply


Thread Tools
Display Modes




Copyright 2006 SmartyDevil.com - Dies Mies Jeschet Boenedoesef Douvema Enitemaus -
666