diff options
author | Russell Belfer <rb@github.com> | 2012-04-17 15:12:50 -0700 |
---|---|---|
committer | Russell Belfer <rb@github.com> | 2012-04-25 10:42:37 -0700 |
commit | 19fa2bc111d50dc2bafb1393b87b5ba119615ae2 (patch) | |
tree | 103a62cf49834958b18562f411abd18b2a438ce6 /src/ignore.c | |
parent | 2bc8fa0227d549006a9870620ca1f2e08a0c305e (diff) | |
download | libgit2-19fa2bc111d50dc2bafb1393b87b5ba119615ae2.tar.gz |
Convert attrs and diffs to use string pools
This converts the git attr related code (including ignores) and
the git diff related code (and implicitly the status code) to use
`git_pools` for storing strings. This reduces the number of small
blocks allocated dramatically.
Diffstat (limited to 'src/ignore.c')
-rw-r--r-- | src/ignore.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/ignore.c b/src/ignore.c index 1827eda82..165754b4d 100644 --- a/src/ignore.c +++ b/src/ignore.c @@ -35,7 +35,9 @@ static int load_ignore_file( GITERR_CHECK_ALLOC(match); } - if (!(error = git_attr_fnmatch__parse(match, context, &scan))) { + if (!(error = git_attr_fnmatch__parse( + match, ignores->pool, context, &scan))) + { match->flags = match->flags | GIT_ATTR_FNMATCH_IGNORE; scan = git__next_line(scan); error = git_vector_insert(&ignores->rules, match); |