works for single-chunk files