diff --git a/lib/utilities.c b/lib/utilities.c index fcd14659..a36fb1b7 100644 --- a/lib/utilities.c +++ b/lib/utilities.c @@ -1230,15 +1230,11 @@ RmOff rm_offset_get_from_fd(int fd, RmOff file_offset, RmOff *file_offset_next, /* check if subsequent extents are contiguous */ if(fm_ext.fe_physical != expected) { /* current extent is not contiguous with previous, so we can stop */ - done = TRUE; + g_free(fm); + break; } } - if(!done && file_offset_next != NULL) { - /* update logical offset of next fragment */ - *file_offset_next = fm_ext.fe_logical + fm_ext.fe_length; - } - if(fm_ext.fe_flags & FIEMAP_EXTENT_DATA_INLINE) { rm_util_set_nullable_bool(is_inline, TRUE); }