CCBC-386: Rewrite server.c and server_negotiate.c against lcbio2

Change-Id: Ic554525e952b2b70bd05b4694d5c31042fb5c549
Reviewed-on: http://review.couchbase.org/35881
Tested-by: Mark Nunberg <mnunberg@haskalah.org>
Reviewed-by: Brett Lawson <brett19@gmail.com>