summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorPatrick Steinhardt <ps@pks.im>2016-02-23 11:48:30 +0100
committerPatrick Steinhardt <ps@pks.im>2016-02-23 11:50:23 +0100
commitc5bd70d13843cc213ec57b10168dd94ed362843b (patch)
tree12d389214dbd13b9032c27e47a78016ca5ad2a41 /src
parent6e2a37556d4793101b71ac83747a3acb31ee3c5b (diff)
downloadlibgit2-c5bd70d13843cc213ec57b10168dd94ed362843b.tar.gz
revwalk: use GITERR_CHECK_ALLOC_BUF
Diffstat (limited to 'src')
-rw-r--r--src/revwalk.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/revwalk.c b/src/revwalk.c
index 89279ed1f..4815a1089 100644
--- a/src/revwalk.c
+++ b/src/revwalk.c
@@ -223,8 +223,7 @@ static int push_glob(git_revwalk *walk, const char *glob, int hide)
git_buf_joinpath(&buf, GIT_REFS_DIR, glob);
else
git_buf_puts(&buf, glob);
- if (git_buf_oom(&buf))
- return -1;
+ GITERR_CHECK_ALLOC_BUF(&buf);
/* If no '?', '*' or '[' exist, we append '/ *' to the glob */
wildcard = strcspn(glob, "?*[");