summaryrefslogtreecommitdiffstats
path: root/Source/cmMakefileLibraryTargetGenerator.cxx
diff options
context:
space:
mode:
authorBill Hoffman <bill.hoffman@kitware.com>2007-06-04 21:17:53 (GMT)
committerBill Hoffman <bill.hoffman@kitware.com>2007-06-04 21:17:53 (GMT)
commitd2b3e06cd0c17646d903986cfb1bc0e75b2c5460 (patch)
tree537f688f63751fff005b67e6de87eae7dc44fe84 /Source/cmMakefileLibraryTargetGenerator.cxx
parent3e57d1f8ad054ca9c531ebdcf45564ab64e903cb (diff)
downloadCMake-d2b3e06cd0c17646d903986cfb1bc0e75b2c5460.zip
CMake-d2b3e06cd0c17646d903986cfb1bc0e75b2c5460.tar.gz
CMake-d2b3e06cd0c17646d903986cfb1bc0e75b2c5460.tar.bz2
ENH: prevent crash
Diffstat (limited to 'Source/cmMakefileLibraryTargetGenerator.cxx')
-rw-r--r--Source/cmMakefileLibraryTargetGenerator.cxx6
1 files changed, 6 insertions, 0 deletions
diff --git a/Source/cmMakefileLibraryTargetGenerator.cxx b/Source/cmMakefileLibraryTargetGenerator.cxx
index 4eaefce..edef367 100644
--- a/Source/cmMakefileLibraryTargetGenerator.cxx
+++ b/Source/cmMakefileLibraryTargetGenerator.cxx
@@ -340,6 +340,12 @@ void cmMakefileLibraryTargetGenerator::CopyFrameworkResources(
{
cmCustomCommandLine line;
cmSourceFile* sf = this->Makefile->GetOrCreateSource(i->c_str());
+ if(!sf)
+ {
+ cmSystemTools::Error(
+ "could not find resource file.", i->c_str());
+ continue;
+ }
std::string dest = outpath + "Resources/";
dest += sf->GetSourceName();
std::string ext = sf->GetSourceExtension();