Fixed Listener handling of conditional GETs with Range headers

If a request had both a Range header and an If-None-Match, and
the Etag matched, the response status was incorrectly set to 206
instead of 304. (This was a bug in the CocoaHTTPServer submodule.)

I also fixed a bug with Range requests of gzip-encoded attachments:
the attachment has to be decoded otherwise the byte range applies to
the gzipped data, not the actual attachment content.
Fixes #317
Fix KVO exceptions after saving a CBLModel

When KVO-observing an object that is itself a property of a model, and then saving the model, the _properties dictionary was cleared —
 this caused the object being observed to be dealloced, triggering an exception.
Fixes #244
Simplified some logic in CBLPuller

Traun pointed out that _caughtUp will always be NO at this point,
since -startChangeTracker is only called from -beginReplicating
after clearing _caughtUp.
Improved handling of CBL_Puller changesTotal count

This should fix the changesTotal temporarily going negative.
Also, if some incoming revisions already exist, it now responds by
increasing changesProcessed instead of lowering changesTotal, which
makes more sense.
Fixes #351

Conflicts:
	Source/CBL_Puller.m
Oops, forgot to push CocoaHTTPServer.
WebSocketChangeTracker: Reset retry interval after successful connection

Fixes #335
Re-index multiple views together

When updating a view's index, also update other views' indexes. This
saves time because a lot of the work (iterating through the sequences,
fetching the documents, looking for conflicts) is shared.

Like CouchDB, I'm grouping views together for this purpose. The other
views that will get updated are the ones sharing the same prefix up
through the first "/". Or if the view name has no "/", it's all the
other views without a "/".
Optimization for naughty map functions that emit 'doc' as value

Instead of storing the whole doc dictionary, store a placeholder ("*").
At query time, detect the placeholder and load the revision body.
A few more view-indexing optimizations
Changed indexing behavior so views with no “/“ in name don’t index together.

There’s a compile-time flag GROUP_VIEWS_BY_DEFAULT that can be defined
to change this back to having all those views form one group.
fix conform path for #import
Fixed equality test for query rows whose value is 'doc'

Regression from the emit-doc optimization (03454e8)
Merge pull request #389 from ManuTroquet/master

fix conform path for #import
Added a unit test for emitting nil values. Fixed some Xcode 6 compile issues.
Workaround to keep CBLJSONReader from being dealloced prematurely

I think this will fix #369.
Avoid unnecessary JSON data-to-string conversions during view indexing
Fixed mistake in JSON string collation Unicode ordering

Character comparison was using ASCII order instead of the real Unicode
collation order. (For example, '_' and '~' were sorting after letters
instead of before.)

This commit also bumps the db version number; the next time a database
is opened its view indexes will be cleared, so they'll be re-indexed
with the new ordering instead of getting an inconsistent mixture of the
old and new orderings.
Fixed FMDB submodule commit reference.
Fixed a case where a view query could use -1 instead of the view_id in the SQL query

https://groups.google.com/d/msgid/mobile-couchbase/aa81a906-188f-445f-b67c-3898503e3683%40googlegroups.com
Fixed bugs saving replication checkpoint

* Updating the checkpoint should not be canceled when the replication goes offline or is told to stop.
* The lastSequence stored in the db at the end should be the lastSequence saved remotely, _not_ the current lastSequence (which may have changed.)
* Added a Sync log message when the checkpoint is successfully saved, for future debugging.