pgsql: Add overflow checks to money type input function

Поиск
Список
Период
Сортировка
От Peter Eisentraut
Тема pgsql: Add overflow checks to money type input function
Дата
Msg-id E1bkMP9-0007Hr-3g@gemulon.postgresql.org
обсуждение исходный текст
Список pgsql-committers
Add overflow checks to money type input function

The money type input function did not have any overflow checks at all.
There were some regression tests that purported to check for overflow,
but they actually checked for the overflow behavior of the int8 type
before casting to money.  Remove those unnecessary checks and add some
that actually check the money input function.

Reviewed-by: Fabien COELHO <coelho@cri.ensmp.fr>

Branch
------
master

Details
-------
http://git.postgresql.org/pg/commitdiff/656df624c0d7b50e1714f2a3a14e143e63799a80

Modified Files
--------------
src/backend/utils/adt/cash.c        | 53 ++++++++++++++++++--
src/test/regress/expected/money.out | 98 ++++++++++++++++++++++++++++++++++---
src/test/regress/sql/money.sql      | 30 ++++++++++--
3 files changed, 165 insertions(+), 16 deletions(-)


В списке pgsql-committers по дате отправления:

Предыдущее
От: Tom Lane
Дата:
Сообщение: pgsql: Tweak targetlist-SRF tests some more.
Следующее
От: Heikki Linnakangas
Дата:
Сообщение: pgsql: Fix and clarify comments on replacement selection.