Skip to content

nil pointer when getting blob #10

@unknwon

Description

@unknwon

// ci is *git.Commit
for _, e := range ci.ListEntries() {
if e.IsDir() || strings.HasPrefix(e.Name(), ".") {
continue
}
rc, err := e.Blob().Data()
// e.Blob().Data() will deference a nil pointer, while e.Blob() is okay.
}

This is caused by this PR #8.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions