fix disk cache trimming