From d94dfe087694d68073f01a51c7357fc4741641d8 Mon Sep 17 00:00:00 2001 From: Junegunn Choi Date: Thu, 19 Mar 2015 19:59:38 +0900 Subject: Fix #151 - reduce initial memory footprint --- src/matcher.go | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src/matcher.go') diff --git a/src/matcher.go b/src/matcher.go index 0879a088..06352f59 100644 --- a/src/matcher.go +++ b/src/matcher.go @@ -134,6 +134,10 @@ func (m *Matcher) scan(request MatchRequest) (*Merger, bool) { } pattern := request.pattern empty := pattern.IsEmpty() + if empty { + return PassMerger(&request.chunks, m.tac), false + } + cancelled := util.NewAtomicBool(false) slices := m.sliceChunks(request.chunks) -- cgit v1.2.3