1
0
Fork 0
mirror of https://github.com/warmcat/libwebsockets.git synced 2025-03-09 00:00:04 +01:00

openssl: allow build with old glibc headers

strnlen requires _GNU_SOURCE prior to glibc 2.10.
This commit is contained in:
Orgad Shaneh 2020-08-30 14:35:27 +03:00 committed by Andy Green
parent 0938607af8
commit edb7d6ffc1

View file

@ -21,6 +21,12 @@
* FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
* IN THE SOFTWARE.
*/
#include "lws_config.h"
#ifdef LWS_HAVE_X509_VERIFY_PARAM_set1_host
/* Before glibc 2.10, strnlen required _GNU_SOURCE */
#define _GNU_SOURCE
#endif
#include <string.h>
#include "private-lib-core.h"