]> thyrsus.com Git - rcs-fast-import.git/commit
Fix importing of inline data
authorMike Fleetwood <mike.fleetwood@googlemail.com>
Thu, 29 Aug 2013 22:43:25 +0000 (23:43 +0100)
committerEric S. Raymond <esr@thyrsus.com>
Tue, 3 Sep 2013 18:19:04 +0000 (14:19 -0400)
commit5294d9dc3598785078ed4eca33e663f639da2a4b
treebcf3598e5222216cbb795c50aeaea3906aee9d5d
parent6f45920c0c75d2cec5ed73345d5c3e1cb47737bd
Fix importing of inline data

Import of inline data was failing because the temporary file containing
the inline data was written to .../.rs<PID>/inline-<OBJID> but was being
accessed from the current working directory .../temp-import-<PID> using
just the file name without a path.  Save the full path to the inline
data file, rather than just the file name.

Test case:

$ cat test-01-inline-data.fastexp
commit refs/heads/master
mark :1
committer Joe Bloggs <joe.bloggs@example.com> 998655365 +0100
data 13
Add file.txt

M 644 inline file.txt
data 21
Contents of file.txt

$ rcs-fast-import -v -v -v < test-01-inline-data.fastexp
rcs-fast-import: repository fast import creates /tmp/test/.rs16719
rcs-fast-import:......(0.00 sec) done.
commit refs/heads/master
rcs-fast-import:    :1 M file.txt
rcs-fast-import: linking inline-164709420 to file.txt
cleaning up......(0.00 sec) done.
rcs-fast-import: cleaning up /tmp/test/.rs16719......(0.00 sec) done.
rcs-fast-import: refusing to step on file.txt: OSError(2, 'No such file or directory').
rcs-fast-import