Add more panic() calls for invalid conditions

This commit is contained in:
Alexander Neumann committed 2015-10-11 20:45:42 +02:00
1 parent 7db2369081
commit f188cf81dc
2 files changed
+11

No files matched your search

+4
View File
@@ -215,6 +215,10 @@ func (idx *Index) generatePackList(selectFn func(indexEntry) bool) ([]*packJSON,
packs := make(map[backend.ID]*packJSON)
for id, blob := range idx.pack {
if blob.packID == nil {
panic("nil pack id")
}
if selectFn != nil && !selectFn(blob) {
continue
}