3 ms·
This also applies to C++ <locale> functions, like std::isspace. Another fun one: With FD_CLR, FD_ISSET, FD_SET you can corrupt memory by merely passing a socke
by guidovranken 5y ago
This also applies to C++ <locale> functions, like std::isspace.
Another fun one: With FD_CLR, FD_ISSET, FD_SET you can corrupt memory by merely passing a socket descriptor that is not 0..1024. Pass a negative integer for some undefined behavior as well (shift by negative value occurs here [1])
[1] https://github.com/lattera/glibc/blob/895ef79e04a953cac1493863bcae29ad85657ee1/misc/sys/select.h#L56 https://github.com/lattera/glibc/blob/895ef79e04a953cac14938...