diff --git a/auth_plugin/ProtoUtils.cc b/auth_plugin/ProtoUtils.cc index dfc6dea7d2..904f2d3744 100644 --- a/auth_plugin/ProtoUtils.cc +++ b/auth_plugin/ProtoUtils.cc @@ -255,13 +255,8 @@ utils::GetXrdSfsPrep(const eos::auth::XrdSfsPrepProto& proto_obj) //------------------------------------------------------------------------------ void utils::DeleteXrdSfsPrep(XrdSfsPrep*& obj) { - if (obj->reqid) { - free(obj->reqid); - } - - if (obj->notify != nullptr) { - free(obj->notify); - } + free(obj->reqid); + free(obj->notify); XrdOucTList* currentPath = obj->paths; diff --git a/fst/http/s3/S3Handler.cc b/fst/http/s3/S3Handler.cc index 1c252c82cd..68f622a54f 100644 --- a/fst/http/s3/S3Handler.cc +++ b/fst/http/s3/S3Handler.cc @@ -132,10 +132,8 @@ S3Handler::HandleRequest(eos::common::HttpRequest* request) if (!mHttpResponse || request->GetBodySize() == 0) { // clean-up left-over objects on error or end-of-put - if (mFile) { - delete mFile; - mFile = 0; - } + delete mFile; + mFile = 0; } } } diff --git a/fst/xrdcl_plugins/RainFile.cc b/fst/xrdcl_plugins/RainFile.cc index 9ad15ed8ef..b70422eafb 100644 --- a/fst/xrdcl_plugins/RainFile.cc +++ b/fst/xrdcl_plugins/RainFile.cc @@ -52,13 +52,8 @@ RainFile::~RainFile() { eos_debug("calling destructor"); - if (pFile) { - delete pFile; - } - - if (pRainFile) { - delete pRainFile; - } + delete pFile; + delete pRainFile; }