More C cursor improvements

* fixes 2 problems with the seek implementation
* adds tests for all that
* cleans up the C code some more
* makes sure that cursor at end (including cursor on empty bucket) always returns NULL key and value
* comment cleanup

@benbjohnson 
/cc @Shopify/reports