aboutsummaryrefslogtreecommitdiff
path: root/src/backend/executor/nodeModifyTable.c
diff options
context:
space:
mode:
authorDavid Rowley <drowley@postgresql.org>2023-04-21 10:02:25 +1200
committerDavid Rowley <drowley@postgresql.org>2023-04-21 10:02:25 +1200
commit63a03aea6bc89060010255e8e61c83f95e1daec8 (patch)
treea28e3634155ca56856f2fdf7284cf11351415633 /src/backend/executor/nodeModifyTable.c
parent94d73f9abdf13e6dd93d96d0e4b197479c8756de (diff)
downloadpostgresql-63a03aea6bc89060010255e8e61c83f95e1daec8.tar.gz
postgresql-63a03aea6bc89060010255e8e61c83f95e1daec8.zip
Fix list_copy_head() with empty Lists
list_copy_head() given an empty List would crash from trying to dereference the List to obtain its length. Since NIL is how we represent an empty List, we should just be returning another empty List in this case. list_copy_head() is new to v16, so let's fix it now before too many people start coding around the buggy NIL behavior. Reported-by: Miroslav Bendik Discussion: https://postgr.es/m/CAPoEpV02WhawuWnmnKet6BqU63bEu7oec0pJc=nKMtPsHMzTXQ@mail.gmail.com
Diffstat (limited to 'src/backend/executor/nodeModifyTable.c')
0 files changed, 0 insertions, 0 deletions