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

Commit03787f6

Browse files
committed
Don't trash input list structure in does_not_exist_skipping().
The trigger and rule cases need to split up the input name list, butthey mustn't corrupt the passed-in data structure, since it could be partof a cached utility-statement parsetree. Per bug #7641.
1 parent9eb80f2 commit03787f6

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

‎src/backend/commands/dropcmds.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -203,13 +203,13 @@ does_not_exist_skipping(ObjectType objtype, List *objname, List *objargs)
203203
caseOBJECT_TRIGGER:
204204
msg=gettext_noop("trigger \"%s\" for table \"%s\" does not exist, skipping");
205205
name=strVal(llast(objname));
206-
args=NameListToString(list_truncate(objname,
206+
args=NameListToString(list_truncate(list_copy(objname),
207207
list_length(objname)-1));
208208
break;
209209
caseOBJECT_RULE:
210210
msg=gettext_noop("rule \"%s\" for relation \"%s\" does not exist, skipping");
211211
name=strVal(llast(objname));
212-
args=NameListToString(list_truncate(objname,
212+
args=NameListToString(list_truncate(list_copy(objname),
213213
list_length(objname)-1));
214214
break;
215215
caseOBJECT_FDW:

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp