maskit opened a new pull request, #9418: URL: https://github.com/apache/trafficserver/pull/9418
We've been occasionally seeing crashes caused by accessing invalid (nullptr) `object_read`. We could add null checks here and there but I don't want to repeat crash-then-bandaid process for it. I think there is a seed that started causing the crashes somewhere and ideally we should find and remove the root cause, but that'd be difficult. This change does not fix the root cause, but should prevent accessing invalid `object_read` where `cache_lookup_result` suggests it's cache-hit and an object should be read and available, by adding accessor functions that restricts setting/getting unreasonable values. It might not be complete, but `object_read` is read at many places that assumes it's cache-hit and returning cache-miss when there's doubt avoids the problematic access. The key change is in HttpTransaction.h. When ATS accesses `cache_lookup_result`, the setter function detects unreasonable change and try to keep it makes sense, and the getter detects outdated result value and return a safer value (i.e. cache miss). -- 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: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
