We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 632665d commit 8a4c465Copy full SHA for 8a4c465
src/web/WebSession.C
@@ -680,9 +680,15 @@ bool WebSession::start(WebResponse *response)
680
{
681
try {
682
app_ = controller_->doCreateApplication(this).release();
683
- if (!app_->internalPathValid_)
684
- if (response->responseType() == WebResponse::ResponseType::Page)
685
- response->setStatus(404);
+ if (app_) {
+ if (!app_->internalPathValid_) {
+ if (response->responseType() == WebResponse::ResponseType::Page) {
686
+ response->setStatus(404);
687
+ }
688
689
+ } else {
690
+ throw WException("WebSession::start: ApplicationCreator returned a nullptr");
691
692
} catch (std::exception& e) {
693
app_ = nullptr;
694
0 commit comments