How should I quit a Qt Program, e.g when loading a data file, and discovered file corruption, and user need to quit this app or re-initiate data file?
Should I:
if you need to close your application from main() you can use this code
int main(int argc, char *argv[]){ QApplication app(argc, argv); ... if(!QSslSocket::supportsSsl()) return app.exit(0); ... return app.exec(); }
The program will terminated if OpenSSL is not installed