Branch Coverage

deps/libgit2/src/reader.c
Criterion Covered Total %
branch 0 84 0.0


line true false branch
38 0 0 if ((error = git_tree_entry_bypath(&tree_entry, reader->tree, filename)) < 0 ||
0 0 if ((error = git_tree_entry_bypath(&tree_entry, reader->tree, filename)) < 0 ||
43 0 0 GIT_ERROR_CHECK_BLOBSIZE(blobsize);
45 0 0 if ((error = git_buf_set(out, git_blob_rawcontent(blob), (size_t)blobsize)) < 0)
48 0 0 if (out_id)
51 0 0 if (out_filemode)
64 0 0 assert(out && tree);
0 0 assert(out && tree);
67 0 0 GIT_ERROR_CHECK_ALLOC(reader);
100 0 0 if ((error = git_buf_joinpath(&path,
104 0 0 if ((error = p_lstat(path.ptr, &st)) < 0) {
105 0 0 if (error == -1 && errno == ENOENT)
0 0 if (error == -1 && errno == ENOENT)
119 0 0 if ((error = git_filter_list_load(&filters, reader->repo, NULL, filename,
123 0 0 if ((error = git_filter_list_apply_to_file(out,
127 0 0 if (out_id || reader->index) {
0 0 if (out_id || reader->index) {
128 0 0 if ((error = git_odb_hash(&id, out->ptr, out->size, GIT_OBJECT_BLOB)) < 0)
132 0 0 if (reader->index) {
133 0 0 if (!(idx_entry = git_index_get_bypath(reader->index, filename, 0)) ||
0 0 if (!(idx_entry = git_index_get_bypath(reader->index, filename, 0)) ||
134 0 0 filemode != idx_entry->mode ||
141 0 0 if (out_id)
144 0 0 if (out_filemode)
161 0 0 assert(out && repo);
0 0 assert(out && repo);
164 0 0 GIT_ERROR_CHECK_ALLOC(reader);
169 0 0 if (validate_index &&
0 0 if (validate_index &&
199 0 0 if ((entry = git_index_get_bypath(reader->index, filename, 0)) == NULL)
202 0 0 if ((error = git_blob_lookup(&blob, reader->repo, &entry->id)) < 0)
205 0 0 if (out_id)
208 0 0 if (out_filemode)
226 0 0 assert(out && repo);
0 0 assert(out && repo);
229 0 0 GIT_ERROR_CHECK_ALLOC(reader);
234 0 0 if (index) {
236 0 0 } else if ((error = git_repository_index__weakptr(&reader->index, repo)) < 0) {
254 0 0 assert(out && reader && filename);
0 0 assert(out && reader && filename);
0 0 assert(out && reader && filename);
261 0 0 if (!reader)