summaryrefslogtreecommitdiffstats
path: root/contrib/ncurses/c++/cursesmain.cc
diff options
context:
space:
mode:
Diffstat (limited to 'contrib/ncurses/c++/cursesmain.cc')
-rw-r--r--contrib/ncurses/c++/cursesmain.cc14
1 files changed, 10 insertions, 4 deletions
diff --git a/contrib/ncurses/c++/cursesmain.cc b/contrib/ncurses/c++/cursesmain.cc
index 03f61bc..6b34b52 100644
--- a/contrib/ncurses/c++/cursesmain.cc
+++ b/contrib/ncurses/c++/cursesmain.cc
@@ -34,7 +34,7 @@
#include "internal.h"
#include "cursesapp.h"
-MODULE_ID("$Id: cursesmain.cc,v 1.7 2001/03/24 21:25:47 tom Exp $")
+MODULE_ID("$Id: cursesmain.cc,v 1.8 2001/07/14 20:54:43 juergen Exp $")
/* This is the default implementation of main() for a NCursesApplication.
* You only have to instantiate a static NCursesApplication object in your
@@ -45,7 +45,13 @@ int main(int argc, char* argv[])
NCursesApplication* A = NCursesApplication::getApplication();
if (!A)
return(1);
- A->handleArgs(argc,argv);
- ::endwin();
- return((*A)());
+ else {
+ int res;
+
+ A->handleArgs(argc,argv);
+ ::endwin();
+ res = (*A)();
+ ::endwin();
+ return(res);
+ }
}
OpenPOWER on IntegriCloud