[
https://issues.apache.org/jira/browse/ZOOKEEPER-4604?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Kezhu Wang updated ZOOKEEPER-4604:
----------------------------------
Component/s: c client
> Creating a COMPLETION_STRING_STAT would set acl_result completion
> -----------------------------------------------------------------
>
> Key: ZOOKEEPER-4604
> URL: https://issues.apache.org/jira/browse/ZOOKEEPER-4604
> Project: ZooKeeper
> Issue Type: Bug
> Components: c client
> Reporter: Adam Yi
> Assignee: Adam Yi
> Priority: Trivial
> Labels: pull-request-available
> Fix For: 3.10.0, 3.8.5, 3.9.5
>
> Time Spent: 10m
> Remaining Estimate: 0h
>
> {code:java}
> case COMPLETION_STRING_STAT:
> c->c.string_stat_result = (string_stat_completion_t)dc;
> case COMPLETION_ACLLIST:
> c->c.acl_result = (acl_completion_t)dc;
> break;{code}
> `c->c` is a union so setting c.acl_result would override
> c.string_stat_result. However, since they're all function pointers pointing
> to the same function, this won't cause any issue as c.string_stat_result is
> still correct. This might cause issue if we change the type of these
> completions in the future.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)