diff options
author | Vicent Marti <tanoku@gmail.com> | 2013-12-13 12:25:48 +0100 |
---|---|---|
committer | Vicent Marti <tanoku@gmail.com> | 2013-12-13 12:25:48 +0100 |
commit | ce33645ff32d68dfd89867468f58fd9c245c26ff (patch) | |
tree | 139ba94664d1fc1ba38d5d0d3b34b02d316532cd /tests/diff/blob.c | |
parent | 452c7de668568f75a97b0438daab9f33b68d605a (diff) | |
download | libgit2-ce33645ff32d68dfd89867468f58fd9c245c26ff.tar.gz |
pool: Cleanup error handling in pool_strdup
Note that `git_pool_strdup` cannot really return any error codes,
because the pool doesn't set errors on OOM.
The only place where `giterr_set_oom` is called is in
`git_pool_strndup`, in a conditional check that is always optimized
away. `n + 1` cannot be zero if `n` is unsigned because the compiler
doesn't take wraparound into account.
This check has been removed altogether because `size_t` is not
particularly going to overflow.
Diffstat (limited to 'tests/diff/blob.c')
0 files changed, 0 insertions, 0 deletions