From: | Robert Haas <robertmhaas(at)gmail(dot)com> |
---|---|
To: | Shigeru Hanada <shigeru(dot)hanada(at)gmail(dot)com> |
Cc: | Alvaro Herrera <alvherre(at)commandprompt(dot)com>, 花田 茂 <hanada(at)metrosystems(dot)co(dot)jp>, Albe Laurenz <laurenz(dot)albe(at)wien(dot)gv(dot)at>, pgsql-hackers <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: Bug in SQL/MED? |
Date: | 2011-07-05 14:02:17 |
Message-ID: | CA+TgmoabyGB2Or5ozgBNAvdc+zFE=oibC-ZUPFrCLy+VwnQB3w@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
2011/7/1 Shigeru Hanada <shigeru(dot)hanada(at)gmail(dot)com>:
> 2011/6/30 Alvaro Herrera <alvherre(at)commandprompt(dot)com>:
>> Excerpts from 花田 茂's message of jue jun 30 06:00:23 -0400 2011:
>>
>>> I attached a patch which fixes file_fdw to check required option
>>> (filename) in its validator function. I think that such requirement
>>> should be checked again in PlanForeignScan(), as it had been so far.
>>> Note that this patch requires fdw.patch has been applied.
>>
>> I think it'd be good to keep the error check in fileGetOptions() just to
>> ensure that we don't crash in case a catalog is messed up with, though
>> I'd degrade it to elog(ERROR) from ereport.
>
> Thanks for the comments. Please find attached a patch. Now file_fdw
> validates filename in:
>
> * file_fdw_validator(), to catch lack of required option at DDL
> * fileGetOptions(), to avoid crash caused by corrupted catalog
>
> I used ereport for the former check, because maybe such error usually
> happens and is visible to users. This criteria was taken from the
> document "Reporting Errors Within the Server".
> http://developer.postgresql.org/pgdocs/postgres/error-message-reporting.html
Do we want to apply this to 9.1 before beta3?
--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company
From | Date | Subject | |
---|---|---|---|
Next Message | Robert Haas | 2011-07-05 14:06:24 | Re: Range Types, constructors, and the type system |
Previous Message | Robert Haas | 2011-07-05 14:00:49 | Re: Small documentation issue |