diff options
author | Adam Kocoloski <kocolosk@apache.org> | 2010-07-28 23:28:26 +0000 |
---|---|---|
committer | Adam Kocoloski <kocolosk@apache.org> | 2010-07-28 23:28:26 +0000 |
commit | ccd81fdcd98c02ca1396e4752831f3a21b66ce3b (patch) | |
tree | 23ad335015738df47287da16caed694de4bae084 /src | |
parent | 7223697dafa234a9123e6f72b826ba11dc58e88f (diff) |
don't require integer seqnums in the changes feed, COUCHDB-838
git-svn-id: https://svn.apache.org/repos/asf/couchdb/trunk@980265 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'src')
-rw-r--r-- | src/couchdb/couch_rep_changes_feed.erl | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/src/couchdb/couch_rep_changes_feed.erl b/src/couchdb/couch_rep_changes_feed.erl index b1d3960d..4c7dc35a 100644 --- a/src/couchdb/couch_rep_changes_feed.erl +++ b/src/couchdb/couch_rep_changes_feed.erl @@ -273,12 +273,10 @@ handle_messages([], State) -> {noreply, State}; handle_messages([<<"{\"results\":[">>|Rest], State) -> handle_messages(Rest, State); -handle_messages([<<"]">>, <<"\"last_seq\":", LastSeqStr/binary>>], State) -> - LastSeq = list_to_integer(?b2l(hd(re:split(LastSeqStr, "}")))), - handle_feed_completion(State#state{last_seq = LastSeq}); -handle_messages([<<"{\"last_seq\":", LastSeqStr/binary>>], State) -> - LastSeq = list_to_integer(?b2l(hd(re:split(LastSeqStr, "}")))), - handle_feed_completion(State#state{last_seq = LastSeq}); +handle_messages([<<"]">>, <<"\"last_seq\":", _/binary>>], State) -> + handle_feed_completion(State); +handle_messages([<<"{\"last_seq\":", _/binary>>], State) -> + handle_feed_completion(State); handle_messages([Chunk|Rest], State) -> #state{ count = Count, |