Skip to content
Snippets Groups Projects
Commit 7c957bc1 authored by Sergey Linev's avatar Sergey Linev
Browse files

[http] small sniffer optimization

use nullptr, reduce includes, remove unnecessary initializer
parent cf1b41c8
No related branches found
No related tags found
No related merge requests found
......@@ -43,8 +43,8 @@ protected:
UInt_t fMask{0}; ///<! defines operation kind
const char *fSearchPath{nullptr}; ///<! current path searched
Int_t fLevel{0}; ///<! current level of hierarchy
TString fItemName{}; ///<! name of current item
TList fItemsNames{}; ///<! list of created items names, need to avoid duplication
TString fItemName; ///<! name of current item
TList fItemsNames; ///<! list of created items names, need to avoid duplication
Int_t fRestriction{0}; ///<! restriction 0 - default, 1 - read-only, 2 - full access
TRootSnifferStore *fStore{nullptr}; ///<! object to store results
......
......@@ -760,7 +760,7 @@ void TRootSniffer::ScanObjectChilds(TRootSnifferScanRec &rec, TObject *obj)
ScanCollection(rec, ((TFolder *)obj)->GetListOfFolders());
} else if (obj->InheritsFrom(TDirectory::Class())) {
TDirectory *dir = (TDirectory *)obj;
ScanCollection(rec, dir->GetList(), 0, dir->GetListOfKeys());
ScanCollection(rec, dir->GetList(), nullptr, dir->GetListOfKeys());
}
if (rec.CanExpandItem()) {
ScanObjectMembers(rec, obj->IsA(), (char *)obj);
......@@ -1846,7 +1846,7 @@ Bool_t TRootSniffer::RegisterCommand(const char *cmdname, const char *method, co
Int_t numargs = 0;
do {
TString nextname = TString::Format("%sarg%d%s", "%", numargs + 1, "%");
if (strstr(method, nextname.Data()) == 0)
if (strstr(method, nextname.Data()) == nullptr)
break;
numargs++;
} while (numargs < 100);
......
......@@ -41,7 +41,6 @@
#include "THttpCallArg.h"
#include <stdlib.h>
#include <vector>
#include <string.h>
//////////////////////////////////////////////////////////////////////////
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment