Fix compilation under LOOP_CHECK_MODE - #13250
Merged
Merged
Conversation
In earlier work, `vol` was renamed to `stripe` throughout the cache. A few occurences of `vol` were missed because they are conditionally compiled. This patch renames `vol` to `stripe` within code switched by the `LOOP_CHECK_MODE` definition.
Contributor
There was a problem hiding this comment.
Pull request overview
This PR fixes build failures when compiling ATS with LOOP_CHECK_MODE enabled by completing the earlier vol → stripe rename in conditionally-compiled cache directory code paths.
Changes:
- Update
LOOP_CHECK_MODEunit-test code to usestripe/stripe->directoryinstead ofvol. - Fix a remaining
volreference indir_clean_bucket()underLOOP_CHECK_MODE.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
src/iocore/cache/unit_tests/test_CacheDir.cc |
Renames vol references to stripe in LOOP_CHECK_MODE-guarded test paths (with one segment-index bug to fix). |
src/iocore/cache/CacheDir.cc |
Replaces an invalid vol->directory reference with stripe->directory in LOOP_CHECK_MODE code. |
| // freelist_length in freelist with loop | ||
| dir_corrupt_bucket(dir_from_offset(vol->header->freelist[s], seg1), s1, vol); | ||
| vol->directory.freelist_length(s1); | ||
| dir_corrupt_bucket(dir_from_offset(stripe->directory.header->freelist[s], seg1), s1, stripe); |
Contributor
Author
There was a problem hiding this comment.
Completely out of scope.
masaori335
approved these changes
Jun 10, 2026
masaori335
left a comment
Contributor
There was a problem hiding this comment.
Thank you for fixing this. Seems I ignored code in this ifdef in the past.
cmcfarlen
pushed a commit
to cmcfarlen/trafficserver
that referenced
this pull request
Jul 29, 2026
In earlier work, `vol` was renamed to `stripe` throughout the cache. A few occurences of `vol` were missed because they are conditionally compiled. This patch renames `vol` to `stripe` within code switched by the `LOOP_CHECK_MODE` definition.
cmcfarlen
pushed a commit
to cmcfarlen/trafficserver
that referenced
this pull request
Jul 29, 2026
In earlier work, `vol` was renamed to `stripe` throughout the cache. A few occurences of `vol` were missed because they are conditionally compiled. This patch renames `vol` to `stripe` within code switched by the `LOOP_CHECK_MODE` definition. (cherry picked from commit 77253da)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
In earlier work,
volwas renamed tostripethroughout the cache. A few occurences ofvolwere missed because they are conditionally compiled. This patch renamesvoltostripewithin code switched by theLOOP_CHECK_MODEdefinition.I compiled with
LOOP_CHECK_MODE, confirmed the compilation failure inmaster, and confirmed the fix. I also ran the CacheDir tests, which passed. It would have been better to run some AuTests as well for this patch, but I don't have a way to run them on my setup yet.