Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Add error handling clause to catch error triplets returned from lucen…

…e_scan.

Fixes: az775

The lucene_parser module only expects errors of the form {error, Reason}
from calling lucene_scan:string, but it can return errors of the form
{error, Reason, Line} and the lack of handling of errors of this form
is causing test failures of the basho_expect cluster membership test.
This change adds a case clause to handle those errors.
  • Loading branch information...
commit 4ae9fca3da798508ec5388bdedbb0198a580d0ee 1 parent 0e16001
@kellymclaughlin kellymclaughlin authored
Showing with 3 additions and 0 deletions.
  1. +3 −0  apps/lucene_parser/src/lucene_parser.erl
View
3  apps/lucene_parser/src/lucene_parser.erl
@@ -27,6 +27,9 @@ parse(DefaultIndex, DefaultField, QueryString) when is_list(DefaultIndex) andals
end;
{error, Error} ->
%% Scanning error.
+ {error, Error};
+ {error, Error, _} ->
+ %% Scanning error.
{error, Error}
end.
Please sign in to comment.
Something went wrong with that request. Please try again.