You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
everything compiles with no warnings or errors. The http and http_2 programs run fine. However, the http_epoll application runs and terminates with the following output:
$ ./http_epoll
terminate called after throwing an instance of 'char const*'
Aborted
Test environment:
$ g++ --version
g++ (Ubuntu 9.4.0-1ubuntu1~16.04) 9.4.0
Copyright (C) 2019 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
$ uname -a
Linux asusubuntu16 4.15.0-142-generic #146~16.04.1-Ubuntu SMP Tue Apr 13 09:27:15 UTC 2021 x86_64 x86_64 x86_64 GNU/Linux
I tried compiling with g++ v5 but got the same result.
The text was updated successfully, but these errors were encountered:
I can't reproduce this, unfortunately. The thrown "const char*" is unfortunate; if you look at the source code it becomes clear that epoll didn't return a ready socket. So for some reason the epoll wait returns without a ready socket -- there can be many reasons for this, I'd recommend using strace to investigate a bit more.
In the examples++/http_examples folder, using modified build.sh of:
#!/bin/bash
g++ -o http http.cpp -lsocket++
g++ -o http_2 http_2.cpp -lsocket++
g++ -o http_epoll http_epoll.cpp -lsocket++
everything compiles with no warnings or errors. The http and http_2 programs run fine. However, the http_epoll application runs and terminates with the following output:
$ ./http_epoll
terminate called after throwing an instance of 'char const*'
Aborted
Test environment:
$ g++ --version
g++ (Ubuntu 9.4.0-1ubuntu1~16.04) 9.4.0
Copyright (C) 2019 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
$ uname -a
Linux asusubuntu16 4.15.0-142-generic #146~16.04.1-Ubuntu SMP Tue Apr 13 09:27:15 UTC 2021 x86_64 x86_64 x86_64 GNU/Linux
I tried compiling with g++ v5 but got the same result.
The text was updated successfully, but these errors were encountered: