(fix) don't abort on unhandled requests

pull/278/head
Ludovic Marcotte 2017-03-09 13:57:27 -05:00
parent 4ecff8a437
commit fbc6bb71a8
1 changed files with 6 additions and 2 deletions

View File

@ -403,8 +403,12 @@ static BOOL debugLeaks;
- (WOResponse *) handleException: (NSException *) _exc
inContext: (WOContext *) _ctx
{
printf("EXCEPTION: %s\n", [[_exc description] cString]);
abort();
WOResponse *resp;
NSLog(@"EXCEPTION: %s\n", [[_exc description] cString]);
resp = [WOResponse responseWithRequest: [_ctx request]];
[resp setStatus: 501];
return resp;
}
/* runtime maintenance */