diff options
author | Tom Lane <tgl@sss.pgh.pa.us> | 2014-01-13 13:07:20 -0500 |
---|---|---|
committer | Tom Lane <tgl@sss.pgh.pa.us> | 2014-01-13 13:07:20 -0500 |
commit | fc27b406817f303e38fbc86d857cead2a5116668 (patch) | |
tree | 5393ec692f5c8c23f377c5646709825254ee9080 /src/backend/storage/buffer/bufmgr.c | |
parent | 5143dfd5713299048c556d69f93bf17108693db9 (diff) | |
download | postgresql-fc27b406817f303e38fbc86d857cead2a5116668.tar.gz postgresql-fc27b406817f303e38fbc86d857cead2a5116668.zip |
Fix possible buffer overrun in contrib/pg_trgm.
Allow for the possibility that folding a string to lower case makes it
longer (due to replacing a character with a longer multibyte character).
This doesn't change the number of trigrams that will be extracted, but
it does affect the required size of an intermediate buffer in
generate_trgm(). Per bug #8821 from Ufuk Kayserilioglu.
Also install some checks that the input string length is not so large
as to cause overflow in the calculations of palloc request sizes.
Back-patch to all supported versions.
Diffstat (limited to 'src/backend/storage/buffer/bufmgr.c')
0 files changed, 0 insertions, 0 deletions