Update vendored library github.com/go-ini/ini

This commit is contained in:
Alexander Neumann 2018-03-30 11:51:01 +02:00
parent 0d01c27c9e
commit 874b3dbbd9
11 changed files with 175 additions and 103 deletions

View file

@ -140,9 +140,14 @@ func (f *File) Section(name string) *Section {
// Section returns list of Section.
func (f *File) Sections() []*Section {
if f.BlockMode {
f.lock.RLock()
defer f.lock.RUnlock()
}
sections := make([]*Section, len(f.sectionList))
for i := range f.sectionList {
sections[i] = f.Section(f.sectionList[i])
for i, name := range f.sectionList {
sections[i] = f.sections[name]
}
return sections
}