Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit7edd2cb

Browse files
committed
Avoid null pointer dereference crash after OOM in Snowball stemmers.
Absorb upstream bug fix (their commite322673a841d9abd69994ae8cd20e191090b6ef4), which prevents a nullpointer dereference crash if SN_create_env() gets a malloc failureat just the wrong point.Thanks to Maksim Korotkov for discovering the null-pointerbug and submitting the fix to upstream snowball.Reported-by: Maksim Korotkov <m.korotkov@postgrespro.ru>Author: Maksim Korotkov <m.korotkov@postgrespro.ru>Discussion:https://postgr.es/m/1d1a46-67ab1000-21-80c451@83151435Backpatch-through: 13
1 parent49a4508 commit7edd2cb

File tree

1 file changed

+1
-1
lines changed
  • src/backend/snowball/libstemmer

1 file changed

+1
-1
lines changed

‎src/backend/snowball/libstemmer/api.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ extern struct SN_env * SN_create_env(int S_size, int I_size)
3434
externvoidSN_close_env(structSN_env*z,intS_size)
3535
{
3636
if (z==NULL)return;
37-
if (S_size)
37+
if (z->S)
3838
{
3939
inti;
4040
for (i=0;i<S_size;i++)

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp