You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@trafficserver.apache.org by "brbzull0 (via GitHub)" <gi...@apache.org> on 2024/08/07 11:25:32 UTC
[PR] NetHandler - Use the right type to hold `additional_accepts` config value. [trafficserver]
brbzull0 opened a new pull request, #11659:
URL: https://github.com/apache/trafficserver/pull/11659
[proxy.config.net.additional_accepts ](https://ci.trafficserver.apache.org/job/Github_Builds/job/docs/5594/artifact/output/11648/docbuild/html/admin-guide/files/records.yaml.en.html#proxy-config-net-additional-accepts) is expected to use `-1` but the code wasn't storing the value into a signed type, so changed from `unsigned` to `signed` as this is what's expected.
This PR also makes sure the records validity check passes.
Original PR -> https://github.com/apache/trafficserver/pull/10098
Part of a fix for https://github.com/apache/trafficserver/issues/11649
--
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.
To unsubscribe, e-mail: github-unsubscribe@trafficserver.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] NetHandler - Use the right type to hold `additional_accepts` config value. [trafficserver]
Posted by "brbzull0 (via GitHub)" <gi...@apache.org>.
brbzull0 merged PR #11659:
URL: https://github.com/apache/trafficserver/pull/11659
--
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.
To unsubscribe, e-mail: github-unsubscribe@trafficserver.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] NetHandler - Use the right type to hold `additional_accepts` config value. [trafficserver]
Posted by "brbzull0 (via GitHub)" <gi...@apache.org>.
brbzull0 commented on PR #11659:
URL: https://github.com/apache/trafficserver/pull/11659#issuecomment-2273362590
[approve ci autest]
--
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.
To unsubscribe, e-mail: github-unsubscribe@trafficserver.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] NetHandler - Use the right type to hold `additional_accepts` config value. [trafficserver]
Posted by "brbzull0 (via GitHub)" <gi...@apache.org>.
brbzull0 commented on PR #11659:
URL: https://github.com/apache/trafficserver/pull/11659#issuecomment-2274160313
[approve ci autest]
--
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.
To unsubscribe, e-mail: github-unsubscribe@trafficserver.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] NetHandler - Use the right type to hold `additional_accepts` config value. [trafficserver]
Posted by "cmcfarlen (via GitHub)" <gi...@apache.org>.
cmcfarlen commented on PR #11659:
URL: https://github.com/apache/trafficserver/pull/11659#issuecomment-2299070893
Cherry-picked to v10.0.x
--
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.
To unsubscribe, e-mail: github-unsubscribe@trafficserver.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] NetHandler - Use the right type to hold `additional_accepts` config value. [trafficserver]
Posted by "sharkleash (via GitHub)" <gi...@apache.org>.
sharkleash commented on PR #11659:
URL: https://github.com/apache/trafficserver/pull/11659#issuecomment-2285045010
Thanks for finding this, would the behavior be the same in this case? It is definitely a bug that additional_accepts isn't a signed int, but doesn't setting an unsigned int to -1, make it equal to 2^32 - 1 (INT32_MAX - 1)? In that case, there's a section of code in NetHandler.cc that adds 1 to that, making it overflow to 0, and then sets it to 2^32 - 1 anyway.
this is that code:
`int config_value = additional_accepts.load(std::memory_order_relaxed) + 1;
return (config_value > 0 ? config_value : INT32_MAX - 1);`
It's certainly a bug, but if the behavior is the same, maybe this doesn't need to go into 10.0.x?
--
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.
To unsubscribe, e-mail: github-unsubscribe@trafficserver.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] NetHandler - Use the right type to hold `additional_accepts` config value. [trafficserver]
Posted by "brbzull0 (via GitHub)" <gi...@apache.org>.
brbzull0 commented on PR #11659:
URL: https://github.com/apache/trafficserver/pull/11659#issuecomment-2285883410
> Thanks for finding this, would the behavior be the same in this case?
No bother, thanks for looking at it. Yes, same behavior.
> It's certainly a bug, but if the behavior is the same, maybe this doesn't need to go into 10.0.x?
Well, it partialy depends on where https://github.com/apache/trafficserver/pull/11667 lands, **if** https://github.com/apache/trafficserver/pull/11667 lands in 10 then this should also land in 10, at least part of this, to avoid:
```
traffic_server ERROR: proxy.config.net.additional_accepts: Default value consistency check failed. default value=-1 pattern=^-1|[0-9]+$.
```
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.
To unsubscribe, e-mail: github-unsubscribe@trafficserver.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org