removing call to close, stdlib closes rpc connection on error