mirror of
https://git.proxmox.com/git/libgit2
synced 2025-08-03 09:28:59 +00:00
Clean up minor details
This commit is contained in:
parent
5961d5ea7f
commit
201566539f
@ -17,7 +17,7 @@ static int resolve_to_tree(
|
|||||||
int err = 0;
|
int err = 0;
|
||||||
git_object *obj = NULL;
|
git_object *obj = NULL;
|
||||||
|
|
||||||
if ((err =git_revparse(&obj, NULL, NULL, repo, identifier)) < 0)
|
if ((err = git_revparse_single(&obj, repo, identifier)) < 0)
|
||||||
return err;
|
return err;
|
||||||
|
|
||||||
switch (git_object_type(obj)) {
|
switch (git_object_type(obj)) {
|
||||||
|
@ -21,7 +21,6 @@
|
|||||||
GIT_BEGIN_DECL
|
GIT_BEGIN_DECL
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
|
||||||
* Find a single object, as specified by a revision string. See `man gitrevisions`,
|
* Find a single object, as specified by a revision string. See `man gitrevisions`,
|
||||||
* or http://git-scm.com/docs/git-rev-parse.html#_specifying_revisions for
|
* or http://git-scm.com/docs/git-rev-parse.html#_specifying_revisions for
|
||||||
* information on the syntax accepted.
|
* information on the syntax accepted.
|
||||||
@ -31,8 +30,7 @@ GIT_BEGIN_DECL
|
|||||||
* @param spec the textual specification for an object
|
* @param spec the textual specification for an object
|
||||||
* @return 0 on success, GIT_ENOTFOUND, GIT_EAMBIGUOUS, GIT_EINVALIDSPEC or an error code
|
* @return 0 on success, GIT_ENOTFOUND, GIT_EAMBIGUOUS, GIT_EINVALIDSPEC or an error code
|
||||||
*/
|
*/
|
||||||
GIT_EXTERN(int) git_revparse_single(git_object **out, git_repository *repo,
|
GIT_EXTERN(int) git_revparse_single(git_object **out, git_repository *repo, const char *spec);
|
||||||
const char *spec);
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -221,7 +221,7 @@ GIT_EXTERN(void) git_revwalk_sorting(git_revwalk *walk, unsigned int sort_mode);
|
|||||||
*
|
*
|
||||||
* The range should be of the form
|
* The range should be of the form
|
||||||
* <commit>..<commit>
|
* <commit>..<commit>
|
||||||
* where each <commit> is in the form accepted by 'git_revparse'.
|
* where each <commit> is in the form accepted by 'git_revparse_single'.
|
||||||
* The left-hand commit will be hidden and the right-hand commit pushed.
|
* The left-hand commit will be hidden and the right-hand commit pushed.
|
||||||
*
|
*
|
||||||
* @param walk the walker being used for the traversal
|
* @param walk the walker being used for the traversal
|
||||||
|
Loading…
Reference in New Issue
Block a user