mirror of
https://git.proxmox.com/git/libgit2
synced 2025-07-05 12:44:01 +00:00
Check for OOM
This commit is contained in:
parent
0beb7fe427
commit
dfda1cf507
@ -345,6 +345,8 @@ static void crlf_cleanup(
|
||||
git_filter *git_crlf_filter_new(void)
|
||||
{
|
||||
struct crlf_filter *f = git__calloc(1, sizeof(struct crlf_filter));
|
||||
if (f == NULL)
|
||||
return NULL;
|
||||
|
||||
f->f.version = GIT_FILTER_VERSION;
|
||||
f->f.attributes = "crlf eol text";
|
||||
|
@ -115,6 +115,8 @@ static int ident_apply(
|
||||
git_filter *git_ident_filter_new(void)
|
||||
{
|
||||
git_filter *f = git__calloc(1, sizeof(git_filter));
|
||||
if (f == NULL)
|
||||
return NULL;
|
||||
|
||||
f->version = GIT_FILTER_VERSION;
|
||||
f->attributes = "+ident"; /* apply to files with ident attribute set */
|
||||
|
Loading…
Reference in New Issue
Block a user