@@ -656,7 +656,7 @@ create_script_for_old_cluster_deletion(char **deletion_script_file_name)
656
656
#endif
657
657
658
658
/* delete old cluster's default tablespace */
659
- fprintf (script , RMDIR_CMD " %s \n" , fix_path_separator (old_cluster .pgdata ));
659
+ fprintf (script , RMDIR_CMD " \"%s\" \n" , fix_path_separator (old_cluster .pgdata ));
660
660
661
661
/* delete old cluster's alternate tablespaces */
662
662
for (tblnum = 0 ; tblnum < os_info .num_tablespaces ; tblnum ++ )
@@ -680,7 +680,7 @@ create_script_for_old_cluster_deletion(char **deletion_script_file_name)
680
680
681
681
for (dbnum = 0 ; dbnum < old_cluster .dbarr .ndbs ; dbnum ++ )
682
682
{
683
- fprintf (script , RMDIR_CMD " %s%s%c%d\n" ,
683
+ fprintf (script , RMDIR_CMD " \" %s%s%c%d\" \n" ,
684
684
fix_path_separator (os_info .tablespaces [tblnum ]),
685
685
fix_path_separator (old_cluster .tablespace_suffix ),
686
686
PATH_SEPARATOR , old_cluster .dbarr .dbs [dbnum ].db_oid );
@@ -692,7 +692,7 @@ create_script_for_old_cluster_deletion(char **deletion_script_file_name)
692
692
* Simply delete the tablespace directory, which might be ".old"
693
693
* or a version-specific subdirectory.
694
694
*/
695
- fprintf (script , RMDIR_CMD " %s%s\n" ,
695
+ fprintf (script , RMDIR_CMD " \" %s%s\" \n" ,
696
696
fix_path_separator (os_info .tablespaces [tblnum ]),
697
697
fix_path_separator (old_cluster .tablespace_suffix ));
698
698
}
0 commit comments