Fossil SCM
When applying a patch, if the file rename fails, make that just a warning not a fatal error, as the warning might be due to file renames on a prior merge. Fix for ticket [21037bfc1296dabc].
Commit
f013384605144a4a16db4e22ce304ef7bd5ff4ae2d59a03be16ebc2e2d2fbecc
Parent
dd9b316179c8aec…
1 file changed
+2
-2
+2
-2
| --- src/patch.c | ||
| +++ src/patch.c | ||
| @@ -496,12 +496,12 @@ | ||
| 496 | 496 | if( mFlags & PATCH_DRYRUN ){ |
| 497 | 497 | fossil_print("%s", blob_str(&cmd)); |
| 498 | 498 | }else{ |
| 499 | 499 | int rc = fossil_unsafe_system(blob_str(&cmd)); |
| 500 | 500 | if( rc ){ |
| 501 | - fossil_fatal("unable to rename files:\n%s", | |
| 502 | - blob_str(&cmd)); | |
| 501 | + fossil_print("%-10s unable to rename files:\n%s", "WARNING!", | |
| 502 | + blob_str(&cmd)); | |
| 503 | 503 | } |
| 504 | 504 | } |
| 505 | 505 | blob_reset(&cmd); |
| 506 | 506 | } |
| 507 | 507 | |
| 508 | 508 |
| --- src/patch.c | |
| +++ src/patch.c | |
| @@ -496,12 +496,12 @@ | |
| 496 | if( mFlags & PATCH_DRYRUN ){ |
| 497 | fossil_print("%s", blob_str(&cmd)); |
| 498 | }else{ |
| 499 | int rc = fossil_unsafe_system(blob_str(&cmd)); |
| 500 | if( rc ){ |
| 501 | fossil_fatal("unable to rename files:\n%s", |
| 502 | blob_str(&cmd)); |
| 503 | } |
| 504 | } |
| 505 | blob_reset(&cmd); |
| 506 | } |
| 507 | |
| 508 |
| --- src/patch.c | |
| +++ src/patch.c | |
| @@ -496,12 +496,12 @@ | |
| 496 | if( mFlags & PATCH_DRYRUN ){ |
| 497 | fossil_print("%s", blob_str(&cmd)); |
| 498 | }else{ |
| 499 | int rc = fossil_unsafe_system(blob_str(&cmd)); |
| 500 | if( rc ){ |
| 501 | fossil_print("%-10s unable to rename files:\n%s", "WARNING!", |
| 502 | blob_str(&cmd)); |
| 503 | } |
| 504 | } |
| 505 | blob_reset(&cmd); |
| 506 | } |
| 507 | |
| 508 |