Fix warnings from visual c compiler

Change-Id: I9919df4b0989599a9e2f7f0c5206d5db00b861c6
Reviewed-on: http://review.couchbase.org/28223
Tested-by: Sergey Avseyev <sergey.avseyev@gmail.com>
Reviewed-by: Trond Norbye <trond.norbye@gmail.com>