From: Volker Lendecke Date: Mon, 19 Aug 2024 07:30:42 +0000 (+0200) Subject: libsmb: Remove unused cli_errno() X-Git-Tag: tdb-1.4.13~1352 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=e071ec1ffe03945d4b856c001551d5215236b574;p=thirdparty%2Fsamba.git libsmb: Remove unused cli_errno() Signed-off-by: Volker Lendecke Reviewed-by: Andreas Schneider --- diff --git a/source3/libsmb/clierror.c b/source3/libsmb/clierror.c index 630a3f30d6b..628c0c82fc9 100644 --- a/source3/libsmb/clierror.c +++ b/source3/libsmb/clierror.c @@ -50,23 +50,6 @@ int cli_status_to_errno(NTSTATUS status) return err; } -/* Return a UNIX errno appropriate for the error received in the last - packet. */ - -int cli_errno(struct cli_state *cli) -{ - bool connected; - int err; - - connected = cli_state_is_connected(cli); - if (!connected) { - return EPIPE; - } - - err = cli_status_to_errno(cli->raw_status); - return err; -} - /* Return true if the last packet was in error */ bool cli_is_error(struct cli_state *cli) diff --git a/source3/libsmb/proto.h b/source3/libsmb/proto.h index 690b56604b1..1cd8dbdaa6d 100644 --- a/source3/libsmb/proto.h +++ b/source3/libsmb/proto.h @@ -224,7 +224,6 @@ NTSTATUS cli_smb(TALLOC_CTX *mem_ctx, struct cli_state *cli, /* The following definitions come from libsmb/clierror.c */ int cli_status_to_errno(NTSTATUS status); -int cli_errno(struct cli_state *cli); bool cli_is_error(struct cli_state *cli); bool cli_state_is_connected(struct cli_state *cli);