You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@zookeeper.apache.org by GitBox <gi...@apache.org> on 2020/10/06 21:14:52 UTC

[GitHub] [zookeeper] ztzg opened a new pull request #1487: ZOOKEEPER-3954: C client: Avoid compilation issue with aggressive inl…

ztzg opened a new pull request #1487:
URL: https://github.com/apache/zookeeper/pull/1487


   The in this PR avoids a confusing and scary compilation issue [encountered by Michael Hudson-Doyle](https://issues.apache.org/jira/browse/ZOOKEEPER-3954) when building the C client with GCC 10 and "aggressive" optimization settings:
   
   > `free_auth_completions` is being inlined into `free_completions`, and this lets gcc see that members of `a_list` are being accessed without initialization
   
   This is (fortunately!) a red herring: what GCC doesn't see is that, in practice, `zoo_lock_auth` always returns zero, and that `a_list` is always initialized in the conditional block which follows it.
   
   That issue is easily "fixed" by removing the `if`.  The rest of the client code doesn't check `zoo_lock_auth`'s return value--and we have bigger issues if unconditional locks start failing anyway.
   
   See also https://github.com/apache/zookeeper/pull/1481.


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [zookeeper] eolivelli commented on pull request #1487: ZOOKEEPER-3954: C client: GCC 10 compilation fixes

Posted by GitBox <gi...@apache.org>.
eolivelli commented on pull request #1487:
URL: https://github.com/apache/zookeeper/pull/1487#issuecomment-706936147


   Ok for all of them


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [zookeeper] ztzg commented on pull request #1487: ZOOKEEPER-3954: C client: GCC 10 compilation fixes

Posted by GitBox <gi...@apache.org>.
ztzg commented on pull request #1487:
URL: https://github.com/apache/zookeeper/pull/1487#issuecomment-706955745


   Thanks!


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [zookeeper] asfgit closed pull request #1487: ZOOKEEPER-3954: C client: GCC 10 compilation fixes

Posted by GitBox <gi...@apache.org>.
asfgit closed pull request #1487:
URL: https://github.com/apache/zookeeper/pull/1487


   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [zookeeper] symat commented on pull request #1487: ZOOKEEPER-3954: C client: GCC 10 compilation fixes

Posted by GitBox <gi...@apache.org>.
symat commented on pull request #1487:
URL: https://github.com/apache/zookeeper/pull/1487#issuecomment-706903747


   I'm going to merge this PR, plus the others open for branch-3.6 and 3.5)
   @eolivelli is it OK for you? (you +1 this one, but not the other two: https://github.com/apache/zookeeper/pull/1486 https://github.com/apache/zookeeper/pull/1481)


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org