From 1a48112342932e9fcd45a1ff5935f1c9c53b83d1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vicent=20Mart=C3=AD?= Date: Fri, 17 Feb 2012 00:13:34 +0100 Subject: error-handling: References Yes, this is error handling solely for `refs.c`, but some of the abstractions leak all ofer the code base. --- src/attr_file.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'src/attr_file.c') diff --git a/src/attr_file.c b/src/attr_file.c index 3783b5ef3..48424123a 100644 --- a/src/attr_file.c +++ b/src/attr_file.c @@ -250,11 +250,12 @@ int git_attr_path__init( git_buf full_path = GIT_BUF_INIT; int error = git_buf_joinpath(&full_path, base, path); if (error == GIT_SUCCESS) - info->is_dir = (git_path_isdir(full_path.ptr) == GIT_SUCCESS); + info->is_dir = (int)git_path_isdir(full_path.ptr); + git_buf_free(&full_path); return error; } - info->is_dir = (git_path_isdir(path) == GIT_SUCCESS); + info->is_dir = (int)git_path_isdir(path); return GIT_SUCCESS; } -- cgit v1.2.3