Fixed Xgetpeername and Xgetsockname APIs.