FIX: correctly handle if path table can not open
This commit is contained in:
parent
29794b24a9
commit
f9468a2967
|
@ -1519,9 +1519,14 @@ void cmake::UpdateConversionPathTable()
|
||||||
if(tablepath)
|
if(tablepath)
|
||||||
{
|
{
|
||||||
std::ifstream table( tablepath );
|
std::ifstream table( tablepath );
|
||||||
std::string a, b;
|
if(!table)
|
||||||
if( table.is_open() && table.good() )
|
|
||||||
{
|
{
|
||||||
|
cmSystemTools::Error("CMAKE_PATH_TRANSLATION_FILE set to ", tablepath, ". CMake can not open file.");
|
||||||
|
cmSystemTools::ReportLastSystemError("CMake can not open file.");
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
std::string a, b;
|
||||||
while(!table.eof())
|
while(!table.eof())
|
||||||
{
|
{
|
||||||
// two entries per line
|
// two entries per line
|
||||||
|
|
Loading…
Reference in New Issue