I started using GCDWebServer version 3.1 in an app last year, and this line in the addHandlerWithMatchBlock
method of GCDWebServer.m
always caused the system to abort immediately:
GWS_DCHECK(_options == nil);
I ended up just changing it to this to avoid the problem:
GWS_DCHECK(_options != nil);
Now I'm updating to the latest version 3.3.2 and see the same problem. My hack still works here, but I would like to know what a real solution would be. Can someone explain?
See docs in header:
Addling handlers while the server is running is not allowed.
Attempting to do this will result in undefined behavior.