BUG: Return proper values

This commit is contained in:
Andy Cedilnik 2005-12-28 16:44:32 -05:00
parent 5d1000e68c
commit 7a49a0ce4a

View File

@ -1379,7 +1379,7 @@ bool cmSystemTools::CreateTar(const char* outFileName, const std::vector<cmStdSt
| 0) == -1) | 0) == -1)
{ {
fprintf(stderr, "tar_open(): %s\n", strerror(errno)); fprintf(stderr, "tar_open(): %s\n", strerror(errno));
return -1; return false;
} }
std::vector<cmStdString>::const_iterator it; std::vector<cmStdString>::const_iterator it;
@ -1395,7 +1395,7 @@ bool cmSystemTools::CreateTar(const char* outFileName, const std::vector<cmStdSt
"tar_append_tree(\"%s\", \"%s\"): %s\n", buf, "tar_append_tree(\"%s\", \"%s\"): %s\n", buf,
pathname, strerror(errno)); pathname, strerror(errno));
tar_close(t); tar_close(t);
return -1; return false;
} }
} }
@ -1403,14 +1403,13 @@ bool cmSystemTools::CreateTar(const char* outFileName, const std::vector<cmStdSt
{ {
fprintf(stderr, "tar_append_eof(): %s\n", strerror(errno)); fprintf(stderr, "tar_append_eof(): %s\n", strerror(errno));
tar_close(t); tar_close(t);
return -1; return false;
} }
if (tar_close(t) != 0) if (tar_close(t) != 0)
{ {
fprintf(stderr, "tar_close(): %s\n", strerror(errno)); fprintf(stderr, "tar_close(): %s\n", strerror(errno));
return -1;
}
std::cout << "CreateTar: " << outFileName << std::endl;
return false; return false;
} }
return true;
}