diff options
author | Jonathan Nieder <jrnieder@gmail.com> | 2010-11-19 18:46:06 -0600 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2010-11-24 14:51:42 -0800 |
commit | 5c28a8b054cb69a37638b0261fc370422c8fab58 (patch) | |
tree | 111356892e3a73a6439fb0506971d178096f6277 /test-svn-fe.c | |
parent | 1f05d07c456e23c0827efbbb3e738afc9f3152e7 (diff) | |
download | git-5c28a8b054cb69a37638b0261fc370422c8fab58.tar.gz |
vcs-svn: Check for errors from open()
test-svn-fe segfaults when passed a bogus path. Simplify debugging by
exiting with a meaningful error message instead.
Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'test-svn-fe.c')
-rw-r--r-- | test-svn-fe.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/test-svn-fe.c b/test-svn-fe.c index 77cf78abcf..b42ba789b1 100644 --- a/test-svn-fe.c +++ b/test-svn-fe.c @@ -9,7 +9,8 @@ int main(int argc, char *argv[]) { if (argc != 2) usage("test-svn-fe <file>"); - svndump_init(argv[1]); + if (svndump_init(argv[1])) + return 1; svndump_read(NULL); svndump_deinit(); svndump_reset(); |