MCPcopy Create free account
hub / github.com/apache/trafficserver / dir_bucket_loop_fix

Function dir_bucket_loop_fix

src/iocore/cache/CacheDir.cc:236–245  ·  view source on GitHub ↗

break the infinite loop in directory entries Note : abuse of the token bit in dir entries

Source from the content-addressed store, hash-verified

234// break the infinite loop in directory entries
235// Note : abuse of the token bit in dir entries
236int
237dir_bucket_loop_fix(Dir *start_dir, int s, Stripe *stripe)
238{
239 if (!dir_bucket_loop_check(start_dir, stripe->directory.get_segment(s))) {
240 Warning("Dir loop exists, clearing segment %d", s);
241 dir_init_segment(s, stripe);
242 return 1;
243 }
244 return 0;
245}
246
247int
248dir_freelist_length(Stripe *stripe, int s)

Callers 8

dir_freelist_lengthFunction · 0.85
dir_bucket_lengthFunction · 0.85
dir_clean_bucketFunction · 0.85
dir_probeFunction · 0.85
dir_overwriteFunction · 0.85
dir_deleteFunction · 0.85
dir_entries_usedFunction · 0.85
make_vol_mapFunction · 0.85

Calls 3

dir_init_segmentFunction · 0.85
get_segmentMethod · 0.80
dir_bucket_loop_checkFunction · 0.70

Tested by

no test coverage detected