From: 鈴木 幸市 <ko...@in...> - 2013-10-01 09:34:51
|
Agree to remove #else .. . Assert is defined under #ifdef ASSERT_ENABLED internally and we don't have to worry about it. Without this symbol defined, Assert will be expanded to null and there's nothing bothering. Regards; --- Koichi Suzuki On 2013/10/01, at 16:43, Ashutosh Bapat <ash...@en...<mailto:ash...@en...>> wrote: We should move the Assert under #ifdef ASSERT_ENABLED as well the definition of old_outEnd. We should remove #else defining old_outEnd to handle->outEnd which is utterly wrong. On Mon, Sep 30, 2013 at 12:15 PM, Koichi Suzuki <koi...@gm...<mailto:koi...@gm...>> wrote: This change was made to eliminate a warning that old_outEnd is not used. To improve both, the patch would be as attached. Regards; --- Koichi Suzuki 2013/9/30 Abbas Butt <abb...@en...<mailto:abb...@en...>> Hi, The commit ae29a966d3286d4e85b3adf162d00f9b1e8b8eae made this change @@ -1132,7 +1132,11 @@ pgxc_node_send_parse(PGXCNodeHandle * handle, const char* statement, /* message length */ int msgLen; int cnt_params; +#if 0 size_t old_outEnd = handle->outEnd; +#else +#define old_outEnd handle->outEnd +#endif which is incorrect. The purpose of the declaration and assignment is to save the current value of handle->outEnd which is later changed in the function. This change makes the following assert in function pgxc_node_send_parse Assert(old_outEnd + ntohl(msgLen) + 1 == handle->outEnd); fail when the query CREATE TABLE junk AS VALUES (1), (2); is run. This patch is required on master as well. Regards -- *Abbas* Architect Ph: 92.334.5100153 Skype ID: gabbasb www.enterprisedb.co<http://www.enterprisedb.co/> <http://www.enterprisedb.com/>m<http://www.enterprisedb.com/> * Follow us on Twitter* @EnterpriseDB Visit EnterpriseDB for tutorials, webinars, whitepapers<http://www.enterprisedb.com/resources-community>and more<http://www.enterprisedb.com/resources-community> ------------------------------------------------------------------------------ October Webinars: Code for Performance Free Intel webinars can help you accelerate application performance. Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most from the latest Intel processors and coprocessors. See abstracts and register > http://pubads.g.doubleclick.net/gampad/clk?id=60133471&iu=/4140/ostg.clktrk _______________________________________________ Postgres-xc-developers mailing list Pos...@li...<mailto:Pos...@li...> https://lists.sourceforge.net/lists/listinfo/postgres-xc-developers ------------------------------------------------------------------------------ October Webinars: Code for Performance Free Intel webinars can help you accelerate application performance. Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most from the latest Intel processors and coprocessors. See abstracts and register > http://pubads.g.doubleclick.net/gampad/clk?id=60133471&iu=/4140/ostg.clktrk _______________________________________________ Postgres-xc-developers mailing list Pos...@li...<mailto:Pos...@li...> https://lists.sourceforge.net/lists/listinfo/postgres-xc-developers -- Best Wishes, Ashutosh Bapat EnterpriseDB Corporation The Postgres Database Company ------------------------------------------------------------------------------ October Webinars: Code for Performance Free Intel webinars can help you accelerate application performance. Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most from the latest Intel processors and coprocessors. See abstracts and register > http://pubads.g.doubleclick.net/gampad/clk?id=60134791&iu=/4140/ostg.clktrk_______________________________________________ Postgres-xc-developers mailing list Pos...@li... https://lists.sourceforge.net/lists/listinfo/postgres-xc-developers |