diff options
| author | akiyamn | 2020-09-10 19:01:48 +1000 |
|---|---|---|
| committer | akiyamn | 2020-09-10 19:01:48 +1000 |
| commit | 9e59c22e43501007d4aa54bd93aabd914273a347 (patch) | |
| tree | 16c86b0eee8a2529071eb087af79061eb1b40800 | |
| parent | 5d66cc376fd5c96fe4357a8f9eca3b5727a6eb9f (diff) | |
| download | fit2100_ass1-9e59c22e43501007d4aa54bd93aabd914273a347.tar.gz fit2100_ass1-9e59c22e43501007d4aa54bd93aabd914273a347.zip | |
Added a separate move message1.0.0-rc3
| -rw-r--r-- | fileutil.c | 8 |
1 files changed, 6 insertions, 2 deletions
@@ -92,8 +92,12 @@ void copy_into_dir(char *file_path, char *dir_path, bool move, bool overwrite){ strcat(new_path, filename); copy_file(file_path, new_path, overwrite); - if (move) unlink(file_path); // Delete the original if `move` is specified - to_stdout("Copy successful\n"); + if (move) { + unlink(file_path); // Delete the original if `move` is specified + to_stdout("Move successful.\n"); + } else { + to_stdout("Copy successful.\n"); + } free(new_path); } |
