Lost work

This commit is contained in:
Jørn Guldberg committed 2019-09-12 22:34:33 +02:00
1 parent 0f6e818ff6
commit 8adca8f575
6 files changed
+174 -166

No files matched your search

+5 -5
View File
@@ -43,7 +43,7 @@ short drop_filename;
String_Array *split_path;
Directory_Table *dir_table = calloc(1, sizeof(Directory_Table));
/* printf("Table index: %lu \n",fsci.master_table_index ); */
disk_service_read_data_from_disk(fsci.master_table_index[0], DEFAULT_TABLE_SIZE, dir_table, 0x7e0);
disk_service_read_data_from_disk(fsci.master_table_index[0], DEFAULT_TABLE_SIZE, dir_table, 0x50);
split_path = string_split_c(path, '/', false);
number_of_traversal = split_path->length;
@@ -118,10 +118,10 @@ unsigned int data_segment;
{
break;
}
disk_service_read_data_from_disk(file->data_pointer[data_pointer_index], DEFAULT_DATA_POINTER_SIZE, tmp_buffer, 0x7e0);
disk_service_read_data_from_disk(file->data_pointer[data_pointer_index], DEFAULT_DATA_POINTER_SIZE, tmp_buffer, 0x50);
print_newline();
print_newline();
memcpy((data + amount_read), data_segment, tmp_buffer, 0x7e0, amount_to_read);
memcpy((data + amount_read), data_segment, tmp_buffer, 0x50, amount_to_read);
data_length -= amount_to_read;
amount_read += amount_to_read;
data_pointer_index = data_pointer_index + 2; /* Rember that we only use 32-bit, and thats why we jump to at a time*/
@@ -141,9 +141,9 @@ unsigned int data_segment;
amount_to_read = ((DEFAULT_DATA_POINTER_SIZE * SECTOR_SIZE) - remaining_offset);
}
disk_service_read_data_from_disk(file->data_pointer[data_pointer_index], DEFAULT_DATA_POINTER_SIZE, tmp_buffer, 0x7e0);
disk_service_read_data_from_disk(file->data_pointer[data_pointer_index], DEFAULT_DATA_POINTER_SIZE, tmp_buffer, 0x50);
memcpy(data, data_segment, (tmp_buffer + remaining_offset), 0x7e0, amount_to_read);
memcpy(data, data_segment, (tmp_buffer + remaining_offset), 0x50, amount_to_read);
data_length -= amount_to_read;
amount_read += amount_to_read;
remaining_offset -= amount_to_read;