apps/s_server.c: Add check for OPENSSL_strdup
authorJiasheng Jiang <jiasheng@iscas.ac.cn>
Fri, 17 Jun 2022 09:44:24 +0000 (17:44 +0800)
committerPauli <pauli@openssl.org>
Wed, 22 Jun 2022 06:57:17 +0000 (16:57 +1000)
commit3ec2baf41dd6a414347f1ff6c7cec6a996e0afe1
treeb1c9e7c6c88a8cb846d5cda20cd277e0bd9ed053
parent2814834bf2f4e7923294326b0251c3a6579b1312
apps/s_server.c: Add check for OPENSSL_strdup

As the potential failure of the OPENSSL_strdup(),
it should be better to check the return value and
return error if fails.

Signed-off-by: Jiasheng Jiang <jiasheng@iscas.ac.cn>
Reviewed-by: Todd Short <todd.short@me.com>
Reviewed-by: Paul Dale <pauli@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/18595)

(cherry picked from commit a6a2dd9f60b3f3e93de1337ee84f9e8f33bc86a8)
apps/s_server.c