summaryrefslogtreecommitdiffstats
path: root/Source/CTest/cmCTestSVN.cxx
diff options
context:
space:
mode:
authorBen Boeckel <ben.boeckel@kitware.com>2014-02-22 00:05:55 (GMT)
committerBrad King <brad.king@kitware.com>2014-03-08 18:05:37 (GMT)
commitb3bf31a5488a19ea3c357e346b882a2ca84c63b6 (patch)
tree42cb81b5ec3c7888ef4f75e68f767f3992c4ec4f /Source/CTest/cmCTestSVN.cxx
parent5af95c396dc780c04444f549b957c2cba7c75309 (diff)
downloadCMake-b3bf31a5488a19ea3c357e346b882a2ca84c63b6.zip
CMake-b3bf31a5488a19ea3c357e346b882a2ca84c63b6.tar.gz
CMake-b3bf31a5488a19ea3c357e346b882a2ca84c63b6.tar.bz2
stringapi: Miscellaneous char* parameters
Diffstat (limited to 'Source/CTest/cmCTestSVN.cxx')
-rw-r--r--Source/CTest/cmCTestSVN.cxx18
1 files changed, 9 insertions, 9 deletions
diff --git a/Source/CTest/cmCTestSVN.cxx b/Source/CTest/cmCTestSVN.cxx
index 89592dd..86dc2f2 100644
--- a/Source/CTest/cmCTestSVN.cxx
+++ b/Source/CTest/cmCTestSVN.cxx
@@ -361,10 +361,10 @@ private:
return true;
}
- virtual void StartElement(const char* name, const char** atts)
+ virtual void StartElement(const std::string& name, const char** atts)
{
this->CData.clear();
- if(strcmp(name, "logentry") == 0)
+ if(name == "logentry")
{
this->Rev = Revision();
this->Rev.SVNInfo = &SVNRepo;
@@ -374,7 +374,7 @@ private:
}
this->Changes.clear();
}
- else if(strcmp(name, "path") == 0)
+ else if(name == "path")
{
this->CurChange = Change();
if(const char* action = this->FindAttribute(atts, "action"))
@@ -389,28 +389,28 @@ private:
this->CData.insert(this->CData.end(), data, data+length);
}
- virtual void EndElement(const char* name)
+ virtual void EndElement(const std::string& name)
{
- if(strcmp(name, "logentry") == 0)
+ if(name == "logentry")
{
this->SVN->DoRevisionSVN(this->Rev, this->Changes);
}
- else if(strcmp(name, "path") == 0 && !this->CData.empty())
+ else if(!this->CData.empty() && name == "path")
{
std::string orig_path(&this->CData[0], this->CData.size());
std::string new_path = SVNRepo.BuildLocalPath( orig_path );
this->CurChange.Path.assign(new_path);
this->Changes.push_back(this->CurChange);
}
- else if(strcmp(name, "author") == 0 && !this->CData.empty())
+ else if(!this->CData.empty() && name == "author")
{
this->Rev.Author.assign(&this->CData[0], this->CData.size());
}
- else if(strcmp(name, "date") == 0 && !this->CData.empty())
+ else if(!this->CData.empty() && name == "date")
{
this->Rev.Date.assign(&this->CData[0], this->CData.size());
}
- else if(strcmp(name, "msg") == 0 && !this->CData.empty())
+ else if(!this->CData.empty() && name == "msg")
{
this->Rev.Log.assign(&this->CData[0], this->CData.size());
}