diff options
Diffstat (limited to 'src/attr_file.c')
-rw-r--r-- | src/attr_file.c | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/src/attr_file.c b/src/attr_file.c index f43375568..bd69c631b 100644 --- a/src/attr_file.c +++ b/src/attr_file.c @@ -34,10 +34,10 @@ int git_attr_file__new( git_attr_file_source source) { git_attr_file *attrs = git__calloc(1, sizeof(git_attr_file)); - GITERR_CHECK_ALLOC(attrs); + GIT_ERROR_CHECK_ALLOC(attrs); if (git_mutex_init(&attrs->lock) < 0) { - giterr_set(GITERR_OS, "failed to initialize lock"); + git_error_set(GIT_ERROR_OS, "failed to initialize lock"); git__free(attrs); return -1; } @@ -56,7 +56,7 @@ int git_attr_file__clear_rules(git_attr_file *file, bool need_lock) git_attr_rule *rule; if (need_lock && git_mutex_lock(&file->lock) < 0) { - giterr_set(GITERR_OS, "failed to lock attribute file"); + git_error_set(GIT_ERROR_OS, "failed to lock attribute file"); return -1; } @@ -147,7 +147,7 @@ int git_attr_file__load( break; } default: - giterr_set(GITERR_INVALID, "unknown file source %d", source); + git_error_set(GIT_ERROR_INVALID, "unknown file source %d", source); return -1; } @@ -219,7 +219,7 @@ int git_attr_file__out_of_date( } default: - giterr_set(GITERR_INVALID, "invalid file type %d", file->source); + git_error_set(GIT_ERROR_INVALID, "invalid file type %d", file->source); return -1; } } @@ -245,7 +245,7 @@ int git_attr_file__parse_buffer( context = attrs->entry->path; if (git_mutex_lock(&attrs->lock) < 0) { - giterr_set(GITERR_OS, "failed to lock attribute file"); + git_error_set(GIT_ERROR_OS, "failed to lock attribute file"); return -1; } @@ -751,7 +751,7 @@ int git_attr_assignment__parse( /* allocate assign if needed */ if (!assign) { assign = git__calloc(1, sizeof(git_attr_assignment)); - GITERR_CHECK_ALLOC(assign); + GIT_ERROR_CHECK_ALLOC(assign); GIT_REFCOUNT_INC(assign); } @@ -785,7 +785,7 @@ int git_attr_assignment__parse( /* allocate permanent storage for name */ assign->name = git_pool_strndup(pool, name_start, scan - name_start); - GITERR_CHECK_ALLOC(assign->name); + GIT_ERROR_CHECK_ALLOC(assign->name); /* if there is an equals sign, find the value */ if (*scan == '=') { @@ -794,7 +794,7 @@ int git_attr_assignment__parse( /* if we found a value, allocate permanent storage for it */ if (scan > value_start) { assign->value = git_pool_strndup(pool, value_start, scan - value_start); - GITERR_CHECK_ALLOC(assign->value); + GIT_ERROR_CHECK_ALLOC(assign->value); } } |