#4 LotroDat-4: Add file truncating in DatIO

Mở
%! (template.HTML=5 năm trước cách đây)đang mở bởi Endevir · 0 ý kiến

There might be some occasions, where we need delete all patch data (ex. clearing patch data if file was modified outside). So it will be good idea to add function in DatIO module, which truncates file to its original size, removing all patch data.

  • This should be TruncateFileToOriginalSize() function, member of DatIO class.
  • It uses ftruncate64() function to truncate file.
  • New size should be equal to file_size (variable, which represents appropriate header value).
  • All corresponding values (actual_dat_size and so on) should be reviewed and modified if needed
There might be some occasions, where we need delete all patch data (ex. clearing patch data if file was modified outside). So it will be good idea to add function in DatIO module, which truncates file to its original size, removing all patch data. * This should be TruncateFileToOriginalSize() function, member of DatIO class. * It uses ftruncate64() function to truncate file. * New size should be equal to file_size (variable, which represents appropriate header value). * All corresponding values (actual_dat_size and so on) should be reviewed and modified if needed
Đăng nhập để tham gia bình luận.
Không có Milestone
Không có người được phân công
1 tham gia
Đang tải...
Hủy bỏ
Lưu
Ở đây vẫn chưa có nội dung nào.