diff --git a/cpp/src/Ice/SSL/SchannelTransceiverI.h b/cpp/src/Ice/SSL/SchannelTransceiverI.h index 637c442dbaf..16f0a1cd964 100644 --- a/cpp/src/Ice/SSL/SchannelTransceiverI.h +++ b/cpp/src/Ice/SSL/SchannelTransceiverI.h @@ -52,13 +52,13 @@ namespace Ice::SSL::Schannel void setBufferSize(int rcvSize, int sndSize) final; private: - IceInternal::SocketOperation sslHandshake(SecBuffer* initialBuffer = nullptr); + [[nodiscard]] IceInternal::SocketOperation sslHandshake(SecBuffer* initialBuffer = nullptr); - size_t decryptMessage(IceInternal::Buffer&); - size_t encryptMessage(IceInternal::Buffer&); + [[nodiscard]] size_t decryptMessage(IceInternal::Buffer&); + [[nodiscard]] size_t encryptMessage(IceInternal::Buffer&); - bool writeRaw(IceInternal::Buffer&); - bool readRaw(IceInternal::Buffer&); + [[nodiscard]] bool writeRaw(IceInternal::Buffer&); + [[nodiscard]] bool readRaw(IceInternal::Buffer&); enum State { diff --git a/cpp/src/Ice/SSL/SecureTransportTransceiverI.h b/cpp/src/Ice/SSL/SecureTransportTransceiverI.h index 7fd2da38e03..d7c248ac12b 100644 --- a/cpp/src/Ice/SSL/SecureTransportTransceiverI.h +++ b/cpp/src/Ice/SSL/SecureTransportTransceiverI.h @@ -36,13 +36,14 @@ namespace Ice::SSL::SecureTransport const std::string&, const Ice::SSL::ClientAuthenticationOptions&); ~TransceiverI(); - IceInternal::NativeInfoPtr getNativeInfo() final; - IceInternal::SocketOperation initialize(IceInternal::Buffer&, IceInternal::Buffer&) final; - IceInternal::SocketOperation closing(bool, std::exception_ptr) final; + [[nodiscard]] IceInternal::NativeInfoPtr getNativeInfo() final; + + [[nodiscard]] IceInternal::SocketOperation initialize(IceInternal::Buffer&, IceInternal::Buffer&) final; + [[nodiscard]] IceInternal::SocketOperation closing(bool, std::exception_ptr) final; void close() final; - IceInternal::SocketOperation write(IceInternal::Buffer&) final; - IceInternal::SocketOperation read(IceInternal::Buffer&) final; + [[nodiscard]] IceInternal::SocketOperation write(IceInternal::Buffer&) final; + [[nodiscard]] IceInternal::SocketOperation read(IceInternal::Buffer&) final; [[nodiscard]] std::string protocol() const final; [[nodiscard]] std::string toString() const final;