Re: bug: fuzzystrmatch levenshtein is wrong - Mailing list pgsql-hackers

From marcin mank
Subject Re: bug: fuzzystrmatch levenshtein is wrong
Date
Msg-id b1b9fac60912070639r2fdf9a60wd507bf3e9ead9136@mail.gmail.com
Whole thread Raw
In response to bug: fuzzystrmatch levenshtein is wrong  (marcin mank <marcin.mank@gmail.com>)
List pgsql-hackers
also there is integer overflow:
postgres=# select levenshtein('aaaaaaaaaaaaaaaa','',1,1000000000,1);levenshtein
--------------1179869184
(1 row)


should we reject arguments greater than,say, 10000 ?
maximum input length is 255 currently, so the maximum numbers involved
would be about 10000*255*2

This would leave some breathing room if we wanted to increase the
maximum input string length.

Greetings
Marcin


pgsql-hackers by date:

Previous
From: Robert Haas
Date:
Subject: Re: EXPLAIN BUFFERS
Next
From: 黄晓骋
Date:
Subject: some questions in postgresql developping