Fossil SCM
Fix an issue with the "R" (rename)" and "C" (copy) commands when interpreting git-fast-export files.
Commit
8e5b01034925671f5fdb086a0c9e84e033d0e12d16e1432bdc46e4842bc26705
Parent
92ab2474355296c…
1 file changed
+2
-2
+2
-2
| --- src/import.c | ||
| +++ src/import.c | ||
| @@ -754,11 +754,11 @@ | ||
| 754 | 754 | pNew = import_add_file(); |
| 755 | 755 | pFile = &gg.aFile[i-1]; |
| 756 | 756 | if( strlen(pFile->zName)>nFrom ){ |
| 757 | 757 | pNew->zName = mprintf("%s%s", zTo, pFile->zName[nFrom]); |
| 758 | 758 | }else{ |
| 759 | - pNew->zName = fossil_strdup(pFile->zName); | |
| 759 | + pNew->zName = fossil_strdup(zTo); | |
| 760 | 760 | } |
| 761 | 761 | pNew->isExe = pFile->isExe; |
| 762 | 762 | pNew->isLink = pFile->isLink; |
| 763 | 763 | pNew->zUuid = fossil_strdup(pFile->zUuid); |
| 764 | 764 | pNew->isFrom = 0; |
| @@ -777,11 +777,11 @@ | ||
| 777 | 777 | pNew = import_add_file(); |
| 778 | 778 | pFile = &gg.aFile[i-1]; |
| 779 | 779 | if( strlen(pFile->zName)>nFrom ){ |
| 780 | 780 | pNew->zName = mprintf("%s%s", zTo, pFile->zName[nFrom]); |
| 781 | 781 | }else{ |
| 782 | - pNew->zName = fossil_strdup(pFile->zName); | |
| 782 | + pNew->zName = fossil_strdup(zTo); | |
| 783 | 783 | } |
| 784 | 784 | pNew->zPrior = pFile->zName; |
| 785 | 785 | pNew->isExe = pFile->isExe; |
| 786 | 786 | pNew->isLink = pFile->isLink; |
| 787 | 787 | pNew->zUuid = pFile->zUuid; |
| 788 | 788 |
| --- src/import.c | |
| +++ src/import.c | |
| @@ -754,11 +754,11 @@ | |
| 754 | pNew = import_add_file(); |
| 755 | pFile = &gg.aFile[i-1]; |
| 756 | if( strlen(pFile->zName)>nFrom ){ |
| 757 | pNew->zName = mprintf("%s%s", zTo, pFile->zName[nFrom]); |
| 758 | }else{ |
| 759 | pNew->zName = fossil_strdup(pFile->zName); |
| 760 | } |
| 761 | pNew->isExe = pFile->isExe; |
| 762 | pNew->isLink = pFile->isLink; |
| 763 | pNew->zUuid = fossil_strdup(pFile->zUuid); |
| 764 | pNew->isFrom = 0; |
| @@ -777,11 +777,11 @@ | |
| 777 | pNew = import_add_file(); |
| 778 | pFile = &gg.aFile[i-1]; |
| 779 | if( strlen(pFile->zName)>nFrom ){ |
| 780 | pNew->zName = mprintf("%s%s", zTo, pFile->zName[nFrom]); |
| 781 | }else{ |
| 782 | pNew->zName = fossil_strdup(pFile->zName); |
| 783 | } |
| 784 | pNew->zPrior = pFile->zName; |
| 785 | pNew->isExe = pFile->isExe; |
| 786 | pNew->isLink = pFile->isLink; |
| 787 | pNew->zUuid = pFile->zUuid; |
| 788 |
| --- src/import.c | |
| +++ src/import.c | |
| @@ -754,11 +754,11 @@ | |
| 754 | pNew = import_add_file(); |
| 755 | pFile = &gg.aFile[i-1]; |
| 756 | if( strlen(pFile->zName)>nFrom ){ |
| 757 | pNew->zName = mprintf("%s%s", zTo, pFile->zName[nFrom]); |
| 758 | }else{ |
| 759 | pNew->zName = fossil_strdup(zTo); |
| 760 | } |
| 761 | pNew->isExe = pFile->isExe; |
| 762 | pNew->isLink = pFile->isLink; |
| 763 | pNew->zUuid = fossil_strdup(pFile->zUuid); |
| 764 | pNew->isFrom = 0; |
| @@ -777,11 +777,11 @@ | |
| 777 | pNew = import_add_file(); |
| 778 | pFile = &gg.aFile[i-1]; |
| 779 | if( strlen(pFile->zName)>nFrom ){ |
| 780 | pNew->zName = mprintf("%s%s", zTo, pFile->zName[nFrom]); |
| 781 | }else{ |
| 782 | pNew->zName = fossil_strdup(zTo); |
| 783 | } |
| 784 | pNew->zPrior = pFile->zName; |
| 785 | pNew->isExe = pFile->isExe; |
| 786 | pNew->isLink = pFile->isLink; |
| 787 | pNew->zUuid = pFile->zUuid; |
| 788 |