@@ -1069,7 +1069,7 @@ get_backup_filelist(pgBackup *backup, bool strict)
10691069 char linked [MAXPGPATH ];
10701070 char compress_alg_string [MAXPGPATH ];
10711071 int64 write_size ,
1072- full_size ,
1072+ uncompressed_size ,
10731073 mode , /* bit length of mode_t depends on platforms */
10741074 is_datafile ,
10751075 is_cfs ,
@@ -1088,8 +1088,6 @@ get_backup_filelist(pgBackup *backup, bool strict)
10881088
10891089 get_control_value_str (buf , "path" , path , sizeof (path ),true);
10901090 get_control_value_int64 (buf , "size" , & write_size , true);
1091- if (!get_control_value_int64 (buf , "full_size" , & full_size , false))
1092- full_size = write_size ;
10931091 get_control_value_int64 (buf , "mode" , & mode , true);
10941092 get_control_value_int64 (buf , "is_datafile" , & is_datafile , true);
10951093 get_control_value_int64 (buf , "is_cfs" , & is_cfs , false);
@@ -1100,7 +1098,6 @@ get_backup_filelist(pgBackup *backup, bool strict)
11001098
11011099 file = pgFileInit (path );
11021100 file -> write_size = (int64 ) write_size ;
1103- file -> uncompressed_size = full_size ;
11041101 file -> mode = (mode_t ) mode ;
11051102 file -> is_datafile = is_datafile ? true : false;
11061103 file -> is_cfs = is_cfs ? true : false;
@@ -1136,6 +1133,11 @@ get_backup_filelist(pgBackup *backup, bool strict)
11361133 if (get_control_value_int64 (buf , "hdr_size" , & hdr_size , false))
11371134 file -> hdr_size = (int ) hdr_size ;
11381135
1136+ if (get_control_value_int64 (buf , "full_size" , & uncompressed_size , false))
1137+ file -> uncompressed_size = uncompressed_size ;
1138+ else
1139+ file -> uncompressed_size = write_size ;
1140+
11391141 if (file -> external_dir_num == 0 )
11401142 set_forkname (file );
11411143
0 commit comments