Skip to content

Commit d4232e7

Browse files
author
Edward Thomson
authored
Apply suggestions from code review
1 parent 7491b3f commit d4232e7

File tree

10 files changed

+13
-14
lines changed

10 files changed

+13
-14
lines changed

include/git2/attr.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -354,7 +354,7 @@ GIT_EXTERN(int) git_attr_cache_flush(
354354
*
355355
* git_attr_add_macro(repo, "binary", "-diff -crlf");
356356
*
357-
* @param repo The repository where to add the macro.
357+
* @param repo The repository to add the macro in.
358358
* @param name The name of the macro.
359359
* @param values The value for the macro.
360360
* @return 0 or an error code.

include/git2/branch.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ GIT_BEGIN_DECL
3434
*
3535
* @param out Pointer where to store the underlying reference.
3636
*
37-
* @param repo the repository where to create the branch.
37+
* @param repo the repository to create the branch in.
3838
*
3939
* @param branch_name Name for the branch; this name is
4040
* validated for consistency. It should also not conflict with

include/git2/commit.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -479,7 +479,7 @@ GIT_EXTERN(int) git_commit_create_buffer(
479479
* to the commit and write it into the given repository.
480480
*
481481
* @param out the resulting commit id
482-
* @param repo the repository where to create the commit.
482+
* @param repo the repository to create the commit in.
483483
* @param commit_content the content of the unsigned commit object
484484
* @param signature the signature to add to the commit. Leave `NULL`
485485
* to create a commit without adding a signature field.

include/git2/config.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -426,7 +426,7 @@ GIT_EXTERN(int) git_config_get_string_buf(git_buf *out, const git_config *cfg, c
426426
* interested in. Use NULL to indicate all
427427
* @param callback the function to be called on each value of the variable
428428
* @param payload opaque pointer to pass to the callback
429-
* @return non-zero to terminate the iteration.
429+
* @return 0 or an error code.
430430
*/
431431
GIT_EXTERN(int) git_config_get_multivar_foreach(const git_config *cfg, const char *name, const char *regexp, git_config_foreach_cb callback, void *payload);
432432

@@ -442,7 +442,7 @@ GIT_EXTERN(int) git_config_get_multivar_foreach(const git_config *cfg, const cha
442442
* @param name the variable's name
443443
* @param regexp regular expression to filter which variables we're
444444
* interested in. Use NULL to indicate all
445-
* @return non-zero to terminate the iteration.
445+
* @return 0 or an error code.
446446
*/
447447
GIT_EXTERN(int) git_config_multivar_iterator_new(git_config_iterator **out, const git_config *cfg, const char *name, const char *regexp);
448448

@@ -750,7 +750,7 @@ GIT_EXTERN(int) git_config_parse_path(git_buf *out, const char *value);
750750
* @param regexp regular expression to match against config names (can be NULL)
751751
* @param callback the function to call on each variable
752752
* @param payload the data to pass to the callback
753-
* @return non-zero to terminate the iteration.
753+
* @return 0 or an error code.
754754
*/
755755
GIT_EXTERN(int) git_config_backend_foreach_match(
756756
git_config_backend *backend,

include/git2/indexer.h

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -136,8 +136,7 @@ GIT_EXTERN(int) git_indexer_commit(git_indexer *idx, git_indexer_progress *stats
136136
* names. This is only correct after the index has been finalized.
137137
*
138138
* @param idx the indexer instance
139-
* @return the packfile's hash. In casewhere the index has not been finalized,
140-
* it will be zeroed out.
139+
* @return the packfile's hash
141140
*/
142141
GIT_EXTERN(const git_oid *) git_indexer_hash(const git_indexer *idx);
143142

include/git2/object.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -221,7 +221,7 @@ GIT_EXTERN(int) git_object_peel(
221221
*
222222
* @param dest Pointer to store the copy of the object
223223
* @param source Original object to copy
224-
* @return 0
224+
* @return 0 or an error code
225225
*/
226226
GIT_EXTERN(int) git_object_dup(git_object **dest, git_object *source);
227227

include/git2/odb.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -348,7 +348,7 @@ GIT_EXTERN(int) git_odb_stream_finalize_write(git_oid *out, git_odb_stream *stre
348348
* Most backends don't implement streaming reads
349349
*
350350
* @param stream the stream
351-
* @param buffer the buffer where to store the readed data.
351+
* @param buffer a user-allocated buffer to store the data in.
352352
* @param len the buffer's length
353353
* @return 0 if the read succeeded, error code otherwise
354354
*/

include/git2/rebase.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -329,7 +329,7 @@ GIT_EXTERN(int) git_rebase_next(
329329
*
330330
* @param index The result index of the last operation.
331331
* @param rebase The in-progress rebase.
332-
* @return 0
332+
* @return 0 or an error code
333333
*/
334334
GIT_EXTERN(int) git_rebase_inmemory_index(
335335
git_index **index,

include/git2/repository.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -931,7 +931,7 @@ GIT_EXTERN(int) git_repository_is_shallow(git_repository *repo);
931931
* @param name where to store the pointer to the name
932932
* @param email where to store the pointer to the email
933933
* @param repo the repository
934-
* @return 0
934+
* @return 0 or an error code
935935
*/
936936
GIT_EXTERN(int) git_repository_ident(const char **name, const char **email, const git_repository *repo);
937937

include/git2/revwalk.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -249,7 +249,7 @@ GIT_EXTERN(int) git_revwalk_push_range(git_revwalk *walk, const char *range);
249249
*
250250
* No parents other than the first for each commit will be enqueued.
251251
*
252-
* @param walk The revisionwlaker.
252+
* @param walk The revision walker.
253253
* @return 0 or an error code
254254
*/
255255
GIT_EXTERN(int) git_revwalk_simplify_first_parent(git_revwalk *walk);
@@ -278,7 +278,7 @@ GIT_EXTERN(git_repository *) git_revwalk_repository(git_revwalk *walk);
278278
*
279279
* @param commit_id oid of Commit
280280
* @param payload User-specified pointer to data to be passed as data payload
281-
* @return non-zero to hide the commmit and it parrent.
281+
* @return non-zero to hide the commmit and it parent.
282282
*/
283283
typedef int GIT_CALLBACK(git_revwalk_hide_cb)(
284284
const git_oid *commit_id,

0 commit comments

Comments
 (0)