summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2014-04-01 15:06:15 (GMT)
committerCMake Topic Stage <kwrobot@kitware.com>2014-04-01 15:06:15 (GMT)
commit242e13bfe622d80ca329119ae4027d739d7fa90f (patch)
tree7c7d678ea86fd9d50dd2d7ad796eec45adfc07ff
parenta5a6d537824d5c05ad6b9e6b4f13b92b492543c4 (diff)
parent8c9c4fe1a6d0c660c7e4e4c1af2cdf2e889fbfbd (diff)
downloadCMake-242e13bfe622d80ca329119ae4027d739d7fa90f.zip
CMake-242e13bfe622d80ca329119ae4027d739d7fa90f.tar.gz
CMake-242e13bfe622d80ca329119ae4027d739d7fa90f.tar.bz2
Merge topic 'clang-warnings'
8c9c4fe1 Remove 'return' statements that can never be reached 50ca77f4 create_test_sourcelist: Initialize variable at declaration
-rw-r--r--Source/CursesDialog/cmCursesOptionsWidget.cxx1
-rw-r--r--Source/cmSystemTools.cxx1
-rw-r--r--Templates/TestDriver.cxx.in3
3 files changed, 1 insertions, 4 deletions
diff --git a/Source/CursesDialog/cmCursesOptionsWidget.cxx b/Source/CursesDialog/cmCursesOptionsWidget.cxx
index d76ba2a..2f4b59e 100644
--- a/Source/CursesDialog/cmCursesOptionsWidget.cxx
+++ b/Source/CursesDialog/cmCursesOptionsWidget.cxx
@@ -59,7 +59,6 @@ bool cmCursesOptionsWidget::HandleInput(int& key, cmCursesMainForm*, WINDOW* w)
{
return false;
}
- return false;
}
void cmCursesOptionsWidget::AddOption(std::string const & option )
diff --git a/Source/cmSystemTools.cxx b/Source/cmSystemTools.cxx
index ef1e37b..5beb36d 100644
--- a/Source/cmSystemTools.cxx
+++ b/Source/cmSystemTools.cxx
@@ -1616,7 +1616,6 @@ long copy_data(struct archive *ar, struct archive *aw)
return (r);
}
}
- return r;
}
bool extract_tar(const char* outFileName, bool verbose,
diff --git a/Templates/TestDriver.cxx.in b/Templates/TestDriver.cxx.in
index 82537ef..0e0a872 100644
--- a/Templates/TestDriver.cxx.in
+++ b/Templates/TestDriver.cxx.in
@@ -58,7 +58,7 @@ static char* lowercase(const char *string)
int main(int ac, char *av[])
{
- int i, NumTests, testNum, partial_match;
+ int i, NumTests, testNum = 0, partial_match;
char *arg, *test_name;
int count;
int testToRun = -1;
@@ -81,7 +81,6 @@ int main(int ac, char *av[])
}
printf("To run a test, enter the test number: ");
fflush(stdout);
- testNum = 0;
if( scanf("%d", &testNum) != 1 )
{
printf("Couldn't parse that input as a number\n");