From: | Teodor Sigaev <teodor(at)sigaev(dot)ru> |
---|---|
To: | Heikki Linnakangas <heikki(dot)linnakangas(at)enterprisedb(dot)com> |
Cc: | Peter Guarino <peterguarino(at)earthlink(dot)net>, pgsql-bugs(at)postgresql(dot)org |
Subject: | Re: BUG #4697: to_tsvector hangs on input |
Date: | 2009-03-10 17:44:57 |
Message-ID: | 49B6A719.6090801@sigaev.ru |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-bugs |
> When the parser sees the "@", it goes into "email state". In email
> state, it recurses, trying to find out if the string after the "@" is a
> valid hostname. That in turn goes into email state, recurses again and
> so forth, until you reach the end of the string. Then, the recursion
> unwinds back to the first @, moving on to the next character. At the
> next "@" the cycle repeats.
True
> Since the recursion only wants to know if the string after "@" is a
> valid hostname, we can stop the recursion as soon as we find out that
> it's not. The attached patch does that.
Committed to HEAD, 8.3 and 8.2, thank you. Previous releases are not affected.
--
Teodor Sigaev E-mail: teodor(at)sigaev(dot)ru
WWW: http://www.sigaev.ru/
From | Date | Subject | |
---|---|---|---|
Next Message | Yuri Cherio | 2009-03-10 18:13:12 | BUG #4698: psql.exe is exits reporting "out of memory" error |
Previous Message | Kyle Butt | 2009-03-09 15:34:39 | Re: Bug with function returning composite types. |