Hi Peter,

+1 for v2, I confirmed the premise: OpenTableList() is only reached from
CreatePublication() and AlterPublicationTables(), i.e. once
per DDL statement, with the lists allocated in the command's context.

Can you add a comment before the return something like
       /*
         * relids, relids_with_rf and relids_with_collist are deliberately
not
         * freed here.  This function runs at most once per DDL command, the
         * surrounding command-lifetime memory context frees them later.
         */
So future readers will not think of it as a bug.
This is only a suggestion, feel free to skip it if you'd rather keep the
patch minimal.

Regards,
Surya Poondla

Reply via email to