make protocol_errorcode_2_text lib function

Change-Id: Iec98bb840629a2b06aa1469cfa7d50625e8b6df0
Reviewed-on: http://review.couchbase.org/28856
Reviewed-by: Michael Wiederhold <mike@couchbase.com>
Tested-by: Trond Norbye <trond.norbye@gmail.com>