Fixed argument to handshake().
Fixed possible crash when COPYUID/APPENDUID is not supported by the server.