Advertisement
TwITe

Untitled

Oct 2nd, 2017
71
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.42 KB | None | 0 0
  1. void store(int id, void* data, int array_length) {
  2.     check_settings();
  3.     unsigned int free_space;
  4.     unsigned int current_data_size = array_length * sizeof(data);
  5.     save_current_data_size(current_data_size);
  6.     FILE * data_file = NULL;
  7.     int last_written_byte_position = 0;
  8.     while (current_data_size != 0) {
  9.         if (data_file == NULL) {
  10.             get_new_file_path();
  11.             const char* file = full_path;
  12.             data_file = fopen(file, "a+b");
  13.         }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement