Fossil SCM
Change the merge conflict marks to identify which part is original content and which part is the content merged in.
Commit
76ae862ec9ee2be80a88efb8a2c871f002420469
Parent
fd8698c8e0e2e57…
2 files changed
+1
-1
+6
-3
+1
-1
| --- src/merge.c | ||
| +++ src/merge.c | ||
| @@ -349,11 +349,11 @@ | ||
| 349 | 349 | blob_read_from_file(&v, zFullPath); |
| 350 | 350 | if( isBinary ){ |
| 351 | 351 | rc = -1; |
| 352 | 352 | blob_zero(&r); |
| 353 | 353 | }else{ |
| 354 | - rc = blob_merge(&p, &m, &v, &r); | |
| 354 | + rc = blob_merge(&p, &v, &m, &r); | |
| 355 | 355 | } |
| 356 | 356 | if( rc>=0 ){ |
| 357 | 357 | if( !nochangeFlag ){ |
| 358 | 358 | blob_write_to_file(&r, zFullPath); |
| 359 | 359 | } |
| 360 | 360 |
| --- src/merge.c | |
| +++ src/merge.c | |
| @@ -349,11 +349,11 @@ | |
| 349 | blob_read_from_file(&v, zFullPath); |
| 350 | if( isBinary ){ |
| 351 | rc = -1; |
| 352 | blob_zero(&r); |
| 353 | }else{ |
| 354 | rc = blob_merge(&p, &m, &v, &r); |
| 355 | } |
| 356 | if( rc>=0 ){ |
| 357 | if( !nochangeFlag ){ |
| 358 | blob_write_to_file(&r, zFullPath); |
| 359 | } |
| 360 |
| --- src/merge.c | |
| +++ src/merge.c | |
| @@ -349,11 +349,11 @@ | |
| 349 | blob_read_from_file(&v, zFullPath); |
| 350 | if( isBinary ){ |
| 351 | rc = -1; |
| 352 | blob_zero(&r); |
| 353 | }else{ |
| 354 | rc = blob_merge(&p, &v, &m, &r); |
| 355 | } |
| 356 | if( rc>=0 ){ |
| 357 | if( !nochangeFlag ){ |
| 358 | blob_write_to_file(&r, zFullPath); |
| 359 | } |
| 360 |
+6
-3
| --- src/merge3.c | ||
| +++ src/merge3.c | ||
| @@ -151,13 +151,16 @@ | ||
| 151 | 151 | int *aC2; /* Changes from pPivot to pV2 */ |
| 152 | 152 | int i1, i2; /* Index into aC1[] and aC2[] */ |
| 153 | 153 | int nCpy, nDel, nIns; /* Number of lines to copy, delete, or insert */ |
| 154 | 154 | int limit1, limit2; /* Sizes of aC1[] and aC2[] */ |
| 155 | 155 | int nConflict = 0; /* Number of merge conflicts seen so far */ |
| 156 | - static const char zBegin[] = "<<<<<<< BEGIN MERGE CONFLICT\n"; | |
| 157 | - static const char zMid[] = "============================\n"; | |
| 158 | - static const char zEnd[] = ">>>>>>> END MERGE CONFLICT\n"; | |
| 156 | + static const char zBegin[] = | |
| 157 | + "<<<<<<< BEGIN MERGE CONFLICT: original content first <<<<<<<\n"; | |
| 158 | + static const char zMid[] = | |
| 159 | + "======= original content above; merged content below =======\n"; | |
| 160 | + static const char zEnd[] = | |
| 161 | + ">>>>>>> END MERGE CONFLICT: merged content last >>>>>>>>>>>>\n"; | |
| 159 | 162 | |
| 160 | 163 | blob_zero(pOut); /* Merge results stored in pOut */ |
| 161 | 164 | |
| 162 | 165 | /* Compute the edits that occur from pPivot => pV1 (into aC1) |
| 163 | 166 | ** and pPivot => pV2 (into aC2). Each of the aC1 and aC2 arrays is |
| 164 | 167 |
| --- src/merge3.c | |
| +++ src/merge3.c | |
| @@ -151,13 +151,16 @@ | |
| 151 | int *aC2; /* Changes from pPivot to pV2 */ |
| 152 | int i1, i2; /* Index into aC1[] and aC2[] */ |
| 153 | int nCpy, nDel, nIns; /* Number of lines to copy, delete, or insert */ |
| 154 | int limit1, limit2; /* Sizes of aC1[] and aC2[] */ |
| 155 | int nConflict = 0; /* Number of merge conflicts seen so far */ |
| 156 | static const char zBegin[] = "<<<<<<< BEGIN MERGE CONFLICT\n"; |
| 157 | static const char zMid[] = "============================\n"; |
| 158 | static const char zEnd[] = ">>>>>>> END MERGE CONFLICT\n"; |
| 159 | |
| 160 | blob_zero(pOut); /* Merge results stored in pOut */ |
| 161 | |
| 162 | /* Compute the edits that occur from pPivot => pV1 (into aC1) |
| 163 | ** and pPivot => pV2 (into aC2). Each of the aC1 and aC2 arrays is |
| 164 |
| --- src/merge3.c | |
| +++ src/merge3.c | |
| @@ -151,13 +151,16 @@ | |
| 151 | int *aC2; /* Changes from pPivot to pV2 */ |
| 152 | int i1, i2; /* Index into aC1[] and aC2[] */ |
| 153 | int nCpy, nDel, nIns; /* Number of lines to copy, delete, or insert */ |
| 154 | int limit1, limit2; /* Sizes of aC1[] and aC2[] */ |
| 155 | int nConflict = 0; /* Number of merge conflicts seen so far */ |
| 156 | static const char zBegin[] = |
| 157 | "<<<<<<< BEGIN MERGE CONFLICT: original content first <<<<<<<\n"; |
| 158 | static const char zMid[] = |
| 159 | "======= original content above; merged content below =======\n"; |
| 160 | static const char zEnd[] = |
| 161 | ">>>>>>> END MERGE CONFLICT: merged content last >>>>>>>>>>>>\n"; |
| 162 | |
| 163 | blob_zero(pOut); /* Merge results stored in pOut */ |
| 164 | |
| 165 | /* Compute the edits that occur from pPivot => pV1 (into aC1) |
| 166 | ** and pPivot => pV2 (into aC2). Each of the aC1 and aC2 arrays is |
| 167 |