char *filename = index_filename(desc);
int ret;
- ret = mmap_full_file(filename, O_RDWR, map);
+ ret = mmap_full_file(filename, O_RDWR, &map->data, &map->size, NULL);
PARA_INFO_LOG("mapping index %s: ret: %d, size: %zu\n", filename, ret, map->size);
free(filename);
return ret;
ds_name = disk_storage_name_of_hash(t, hash);
FOR_EACH_DISK_STORAGE_COLUMN(i, t, cd) {
filename = disk_storage_path(t, i, ds_name);
- ret = mmap_full_file(filename, O_RDONLY, &obj);
+ ret = mmap_full_file(filename, O_RDONLY, &obj.data, &obj.size, NULL);
free(filename);
if (ret < 0)
goto out;