diff options
| author | Vicent Martà <vicent@github.com> | 2013-03-01 14:28:47 -0800 |
|---|---|---|
| committer | Vicent Martà <vicent@github.com> | 2013-03-01 14:28:47 -0800 |
| commit | 01be786319238fd6507a08316d1c265c1a89407f (patch) | |
| tree | 15680b3ede486d56a149625f2d3d7245c7293c00 /src | |
| parent | 47f70846aae7605297c943282ac19af2e2c8c206 (diff) | |
| parent | 487fc724ffa0d0260fc4c2a3ab0ea0d5d2ebe81d (diff) | |
| download | libgit2-01be786319238fd6507a08316d1c265c1a89407f.tar.gz | |
Merge pull request #1382 from arrbee/fix-diff-patch-a-different-way
Allow empty config object and use it for tests
Diffstat (limited to 'src')
| -rw-r--r-- | src/config.c | 6 |
1 files changed, 0 insertions, 6 deletions
diff --git a/src/config.c b/src/config.c index ce105089e..d6aa3078c 100644 --- a/src/config.c +++ b/src/config.c @@ -426,8 +426,6 @@ static int get_string(const char **out, const git_config *cfg, const char *name) file_internal *internal; unsigned int i; - assert(cfg->files.length); - git_vector_foreach(&cfg->files, i, internal) { int res = get_string_at_file(out, internal->file, name); @@ -466,8 +464,6 @@ int git_config_get_entry(const git_config_entry **out, const git_config *cfg, co file_internal *internal; unsigned int i; - assert(cfg->files.length); - *out = NULL; git_vector_foreach(&cfg->files, i, internal) { @@ -488,8 +484,6 @@ int git_config_get_multivar(const git_config *cfg, const char *name, const char int ret = GIT_ENOTFOUND; size_t i; - assert(cfg->files.length); - /* * This loop runs the "wrong" way 'round because we need to * look at every value from the most general to most specific |
