diff options
author | Martin Langhoff <martin@catalyst.net.nz> | 2005-11-02 13:48:22 +1300 |
---|---|---|
committer | Junio C Hamano <junkio@cox.net> | 2005-11-01 16:57:14 -0800 |
commit | d44e8cf0298a794648271cbff2f74a0063a672b3 (patch) | |
tree | 804fbd681d434901296742668296c822cd6d21fe /git-cvsimport.perl | |
parent | Do not install backward compatibility links anymore. (diff) | |
download | tgif-d44e8cf0298a794648271cbff2f74a0063a672b3.tar.xz |
cvsimport: catch error condition where cvs host disappears
Add error handling for cases where the cvs server goes away unexpectedly.
While I don't know why the cvs server is so erratic, we should definitely
exit here before committing bogus files.
Signed-off-by: Martin Langhoff <martin@catalyst.net.nz>
Signed-off-by: Junio C Hamano <junkio@cox.net>
Diffstat (limited to 'git-cvsimport.perl')
-rwxr-xr-x | git-cvsimport.perl | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/git-cvsimport.perl b/git-cvsimport.perl index bbb83fb71c..e3cad5a1ca 100755 --- a/git-cvsimport.perl +++ b/git-cvsimport.perl @@ -337,6 +337,10 @@ sub file { } close ($fh); + if ($res eq '') { + die "Looks like the server has gone away while fetching $fn $rev -- exiting!"; + } + return ($name, $res); } |