Fix comment on how temp files and subtransactions are handled master github/master
authorHeikki Linnakangas <heikki.linnakangas@iki.fi>
Thu, 11 Dec 2025 13:57:11 +0000 (15:57 +0200)
committerHeikki Linnakangas <heikki.linnakangas@iki.fi>
Thu, 11 Dec 2025 13:57:11 +0000 (15:57 +0200)
The comment was accurate a long time ago, but not any more. I failed
to update the comment in commit ab3148b712.

src/backend/storage/file/fd.c

index e9eaaf9c829331313e3654f1801671bee1b8200b..716fd7749b65da70b81cf6880d952a1cff615e30 100644 (file)
@@ -3185,9 +3185,10 @@ GetNextTempTableSpace(void)
 /*
  * AtEOSubXact_Files
  *
 /*
  * AtEOSubXact_Files
  *
- * Take care of subtransaction commit/abort.  At abort, we close temp files
- * that the subtransaction may have opened.  At commit, we reassign the
- * files that were opened to the parent subtransaction.
+ * Take care of subtransaction commit/abort.  At abort, we close AllocateDescs
+ * that the subtransaction may have opened.  At commit, we reassign them to
+ * the parent subtransaction.  (Temporary files are tracked by ResourceOwners
+ * instead.)
  */
 void
 AtEOSubXact_Files(bool isCommit, SubTransactionId mySubid,
  */
 void
 AtEOSubXact_Files(bool isCommit, SubTransactionId mySubid,