summaryrefslogtreecommitdiffstats
path: root/Source/CursesDialog/ccmake.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'Source/CursesDialog/ccmake.cxx')
-rw-r--r--Source/CursesDialog/ccmake.cxx10
1 files changed, 9 insertions, 1 deletions
diff --git a/Source/CursesDialog/ccmake.cxx b/Source/CursesDialog/ccmake.cxx
index e46278a..fad6315 100644
--- a/Source/CursesDialog/ccmake.cxx
+++ b/Source/CursesDialog/ccmake.cxx
@@ -127,7 +127,15 @@ int main(int argc, char** argv)
cmCursesMainForm* myform;
myform = new cmCursesMainForm(args, x);
- myform->LoadCache(cacheDir.c_str());
+ if(myform->LoadCache(cacheDir.c_str()))
+ {
+ curses_clear();
+ touchwin(stdscr);
+ endwin();
+ delete myform;
+ std::cerr << "Error running cmake::LoadCache(). Aboriting.\n";
+ return 1;
+ }
cmSystemTools::SetErrorCallback(CMakeErrorHandler, myform);