Fix some typos

2024-01-21 Thread Yongtao Huang
Hi all, As the title said, just fix some typos. Regards Yongtao Huang 0001-Fix-some-typos.patch Description: Binary data

Re: Optimize duplicate code and fix memory leak in function fetch_remote_table_info()

2024-01-19 Thread Yongtao Huang
Hi, > So whatever it leaks will be released at the transaction end. I learned it. thank you very much for your explanation. Regards, Yongtao Huang Tom Lane 于2024年1月20日周六 12:34写道: > Yongtao Huang writes: > > (1) I think *pfree(pub_names.data)* is necessary. > > Really?

Re: Optimize duplicate code and fix memory leak in function fetch_remote_table_info()

2024-01-19 Thread Yongtao Huang
Thanks for your review. (1) I think *pfree(pub_names.data)* is necessary. (2) Agree with you. Considering that the new function is only called twice, not encapsulating it into a function is not a huge problem. Best wishes Yongtao Huang Michael Paquier 于2024年1月20日周六 11:13写道: > On Fri,

Optimize duplicate code and fix memory leak in function fetch_remote_table_info()

2024-01-19 Thread Yongtao Huang
tringInfoString(_names, ", "); appendStringInfoString(_names, quote_literal_cstr(pubname)); } ``` I wanna integrate them into one function `make_pubname_list()` to make the code neater. Thanks for your time. Regards Yongtao Huang 0001-Optimize-duplicate-code-and-fix-memory-leak-in-table.patch Description: Binary data

Fix incorrect format placeholders in walreceiver.c

2024-01-18 Thread Yongtao Huang
Hi all, I think the correct placeholder for var *startoff* should be *%d*. Thanks for your time. Best Yongtao Huang 0001-Fix-incorrect-format-placeholders-in-walreceiver.c.patch Description: Binary data

Re: Fix a typo of func DecodeInsert()

2024-01-16 Thread Yongtao Huang
, XLogRecordBuffer *buf) /* * Parse XLOG_HEAP_DELETE from wal into proper tuplebufs. * * Deletes can possibly contain the old primary key. */ static void DecodeDelete(LogicalDecodingContext *ctx, XLogRecordBuffer *buf) ``` Best wishes Yongtao Huang Richard Guo 于2024年1月17日周三 09:10写道

Fix a typo of func DecodeInsert()

2024-01-16 Thread Yongtao Huang
Hi all, I think the comment above the function DecodeInsert() in src/backend/replication/logical/decode.c should be + * *Inserts *can contain the new tuple. , rather than - * *Deletes *can contain the new tuple. Please correct me if I'm wrong, thanks a lot.