Fix file copy regression by removing static declaration of file_info_t structure
This commit is contained in:
parent
40d42f278d
commit
c7373142a8
8 changed files with 12 additions and 12 deletions
|
@ -175,7 +175,7 @@ char *ask_location(const char*msg, const char *src_dir, const char *dst_org)
|
|||
do
|
||||
{
|
||||
DIR* dir;
|
||||
static file_info_t dir_list = {
|
||||
file_info_t dir_list = {
|
||||
.list = TD_LIST_HEAD_INIT(dir_list.list),
|
||||
.name = NULL
|
||||
};
|
||||
|
|
|
@ -272,7 +272,7 @@ static int dir_whole_partition_log_aux(disk_t *disk, const partition_t *partitio
|
|||
static unsigned int dir_nbr=0;
|
||||
static unsigned long int inode_known[MAX_DIR_NBR];
|
||||
const unsigned int current_directory_namelength=strlen(dir_data->current_directory);
|
||||
static file_info_t dir_list = {
|
||||
file_info_t dir_list = {
|
||||
.list = TD_LIST_HEAD_INIT(dir_list.list),
|
||||
.name = NULL
|
||||
};
|
||||
|
|
|
@ -594,7 +594,7 @@ static void copy_dir(WINDOW *window, disk_t *disk, const partition_t *partition,
|
|||
{
|
||||
static unsigned int dir_nbr=0;
|
||||
static unsigned long int inode_known[MAX_DIR_NBR];
|
||||
static file_info_t dir_list = {
|
||||
file_info_t dir_list = {
|
||||
.list = TD_LIST_HEAD_INIT(dir_list.list),
|
||||
.name = NULL
|
||||
};
|
||||
|
|
|
@ -326,7 +326,7 @@ static unsigned int fat32_find_root_cluster(disk_t *disk_car,const partition_t *
|
|||
#endif
|
||||
unsigned char *buffer;
|
||||
int ind_stop=0;
|
||||
static file_info_t rootdir_list= {
|
||||
file_info_t rootdir_list= {
|
||||
.list = TD_LIST_HEAD_INIT(rootdir_list.list),
|
||||
.name = NULL
|
||||
};
|
||||
|
@ -373,7 +373,7 @@ static unsigned int fat32_find_root_cluster(disk_t *disk_car,const partition_t *
|
|||
(buffer[1*0x20+0xB]!=ATTR_EXT && (buffer[1*0x20+0xB]&ATTR_DIR)!=0) && (cluster==0)
|
||||
&& (buffer[0x40]!=0)) /* First-level directory */
|
||||
{
|
||||
static file_info_t dir_list = {
|
||||
file_info_t dir_list = {
|
||||
.list = TD_LIST_HEAD_INIT(dir_list.list),
|
||||
.name = NULL
|
||||
};
|
||||
|
@ -504,7 +504,7 @@ static unsigned int fat32_find_root_cluster(disk_t *disk_car,const partition_t *
|
|||
}
|
||||
}
|
||||
{
|
||||
static file_info_t dir_list = {
|
||||
file_info_t dir_list = {
|
||||
.list = TD_LIST_HEAD_INIT(dir_list.list),
|
||||
.name = NULL
|
||||
};
|
||||
|
@ -821,7 +821,7 @@ static int analyse_dir_entries2(disk_t *disk_car,const partition_t *partition, c
|
|||
{
|
||||
unsigned char *buffer_dir;
|
||||
unsigned int root_dir_size;
|
||||
static file_info_t dir_list = {
|
||||
file_info_t dir_list = {
|
||||
.list = TD_LIST_HEAD_INIT(dir_list.list),
|
||||
.name = NULL
|
||||
};
|
||||
|
|
|
@ -241,7 +241,7 @@ static int fat_unformat_aux(struct ph_param *params, const struct ph_options *op
|
|||
memcmp(buffer, ". ", 8+3)==0 &&
|
||||
memcmp(&buffer[0x20], ".. ", 8+3)==0)
|
||||
{
|
||||
static file_info_t dir_list = {
|
||||
file_info_t dir_list = {
|
||||
.list = TD_LIST_HEAD_INIT(dir_list.list),
|
||||
.name = NULL
|
||||
};
|
||||
|
|
|
@ -171,7 +171,7 @@ int repair_MFT(disk_t *disk_car, partition_t *partition, const int verbose, cons
|
|||
}
|
||||
if(res1==0)
|
||||
{
|
||||
static file_info_t dir_list = {
|
||||
file_info_t dir_list = {
|
||||
.list = TD_LIST_HEAD_INIT(dir_list.list),
|
||||
.name = NULL
|
||||
};
|
||||
|
@ -191,7 +191,7 @@ int repair_MFT(disk_t *disk_car, partition_t *partition, const int verbose, cons
|
|||
res2=dir_partition_ntfs_init(disk_car,partition,&dir_data,verbose);
|
||||
if(res2==0)
|
||||
{
|
||||
static file_info_t dir_list = {
|
||||
file_info_t dir_list = {
|
||||
.list = TD_LIST_HEAD_INIT(dir_list.list),
|
||||
.name = NULL
|
||||
};
|
||||
|
|
|
@ -1661,7 +1661,7 @@ int ntfs_undelete_part(disk_t *disk_car, const partition_t *partition, const int
|
|||
break;
|
||||
default:
|
||||
{
|
||||
static file_info_t dir_list = {
|
||||
file_info_t dir_list = {
|
||||
.list = TD_LIST_HEAD_INIT(dir_list.list),
|
||||
.name = NULL
|
||||
};
|
||||
|
|
|
@ -311,7 +311,7 @@ static int photorec_aux(struct ph_param *params, const struct ph_options *option
|
|||
|
||||
if(file_recovery.file_stat->file_hint==&file_hint_dir && options->verbose > 0)
|
||||
{ /* FAT directory found, list the file */
|
||||
static file_info_t dir_list = {
|
||||
file_info_t dir_list = {
|
||||
.list = TD_LIST_HEAD_INIT(dir_list.list),
|
||||
.name = NULL
|
||||
};
|
||||
|
|
Loading…
Reference in a new issue