diff options
author | Russell Belfer <rb@github.com> | 2012-12-18 15:12:06 -0800 |
---|---|---|
committer | Russell Belfer <rb@github.com> | 2013-01-04 15:23:47 -0800 |
commit | 6ac724afbe0b1244f84b9acc5dc8be0646be5ce3 (patch) | |
tree | 205786337ee4a2485dbbfb2c19bf2480b9ca9947 /src/attr.c | |
parent | e9e20c8474b4f7ecdb1076c2f2d9c06f21e6be5b (diff) | |
download | libgit2-6ac724afbe0b1244f84b9acc5dc8be0646be5ce3.tar.gz |
Clear error to avoid leaving invalid error behind
Diffstat (limited to 'src/attr.c')
-rw-r--r-- | src/attr.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/attr.c b/src/attr.c index 95d63bea8..1b414417e 100644 --- a/src/attr.c +++ b/src/attr.c @@ -572,8 +572,10 @@ static int collect_attr_files( error = git_futils_find_system_file(&dir, GIT_ATTR_FILE_SYSTEM); if (!error) error = push_attr_file(repo, files, NULL, dir.ptr); - else if (error == GIT_ENOTFOUND) + else if (error == GIT_ENOTFOUND) { + giterr_clear(); error = 0; + } } cleanup: |