Fixed adding data after or before beginning of the file