HUGE BUG - Please fix!!!
HUGE BUG - Please fix!!!
От:
Alexis Wilke <alexis_wilke@yahoo.com>
Дата:
Hi guys,
I don't want to do a patch for a one character error. Yet, that's a HUGE
error and it really needs to be fixed.
Once you have a pg_database file which is over 1 page, it CRASHES. That's
what it did on me. Yes! I have many databases or rather, I often destroy
my databases to regenerate them from scratch (that's for me the easiest
way to do it). Because of that, the pg_database is now two pages.
The utils/misc/database.c has a function called GetRawDatabaseInfo()
which reads that file "on its own". There is a HUGE bug in there, and
it may not always crash a system, but it really needs to be fixed.
At line #183, you have a for() loop which looks like this (since at
least V6.5.0 and still present in V7.0.3):
for (i = 0; i <= max; i++)
All the other such loops start with an index of 1, not zero. And
therefore you want the <=. In this special case loop (or are all
the others special cases?!?) you need to use the following:
for(i = 0; i < max; i++)
Please, I know it's easier when you get a patch, but FIX IT. It's
not fun to try to access your database and have the backend crash
because of such a tiny bug!
Thank you for all your work.
Alexis Wilke
Director
Made to Order Software, Ltd
e-mail: alexis@m2sow.com
Web Page: http://www.m2osw.com
Company e-mail: contact@m2osw.com
Phone: 020 8748 9898 +(44) 20 8748 9898
Fax: 020 8748 4250 +(44) 20 8748 4250
Address: Britannia House 1-11 Glenthorne Road Hammersmith London W6 0LF United Kingdom
__________________________________________________
Do You Yahoo!?
Get email at your own domain with Yahoo! Mail.
http://personal.mail.yahoo.com/?.refer=text
Re: HUGE BUG - Please fix!!!
От:
Bruce Momjian <pgman@candle.pha.pa.us>
Дата:
This is fixed in current 7.1RC1 sources. > Hi guys, > > I don't want to do a patch for a one character error. Yet, that's a HUGE > error and it really needs to be fixed. > > Once you have a pg_database file which is over 1 page, it CRASHES. That's > what it did on me. Yes! I have many databases or rather, I often destroy > my databases to regenerate them from scratch (that's for me the easiest > way to do it). Because of that, the pg_database is now two pages. > > The utils/misc/database.c has a function called GetRawDatabaseInfo() > which reads that file "on its own". There is a HUGE bug in there, and > it may not always crash a system, but it really needs to be fixed. > > At line #183, you have a for() loop which looks like this (since at > least V6.5.0 and still present in V7.0.3): > > for (i = 0; i <= max; i++) > > All the other such loops start with an index of 1, not zero. And > therefore you want the <=. In this special case loop (or are all > the others special cases?!?) you need to use the following: > > for(i = 0; i < max; i++) > > Please, I know it's easier when you get a patch, but FIX IT. It's > not fun to try to access your database and have the backend crash > because of such a tiny bug! > > Thank you for all your work. > > > > Alexis Wilke > Director > Made to Order Software, Ltd > > e-mail: alexis@m2sow.com > > Web Page: http://www.m2osw.com > Company e-mail: contact@m2osw.com > Phone: 020 8748 9898 +(44) 20 8748 9898 > Fax: 020 8748 4250 +(44) 20 8748 4250 > Address: Britannia House > 1-11 Glenthorne Road > Hammersmith > London W6 0LF > United Kingdom > > > __________________________________________________ > Do You Yahoo!? > Get email at your own domain with Yahoo! Mail. > http://personal.mail.yahoo.com/?.refer=text > > ---------------------------(end of broadcast)--------------------------- > TIP 3: if posting/reading through Usenet, please send an appropriate > subscribe-nomail command to majordomo@postgresql.org so that your > message can get through to the mailing list cleanly > -- Bruce Momjian | http://candle.pha.pa.us pgman@candle.pha.pa.us | (610) 853-3000 + If your life is a hard drive, | 830 Blythe Avenue + Christ can be your backup. | Drexel Hill, Pennsylvania 19026