ltp: close mq_close/3-1 testcase when open CONFIG_FDCHECK

Caused the cause will used after free on fd

Signed-off-by: haopengxiang <haopengxiang@xiaomi.com>
Signed-off-by: ligd <liguiding1@xiaomi.com>
This commit is contained in:
haopengxiang 2025-03-27 00:10:06 +08:00 committed by Xiang Xiao
parent 429f24afbd
commit 680dca1121
2 changed files with 4 additions and 2 deletions

View file

@ -119,7 +119,8 @@ if(CONFIG_TESTING_LTP)
${TESTDIR}/conformance/interfaces/sigprocmask/4-1.c)
if(CONFIG_FDCHECK)
list(APPEND BLACKSRCS ${TESTDIR}/conformance/interfaces/mq_close/4-1.c)
list(APPEND BLACKSRCS ${TESTDIR}/conformance/interfaces/mq_close/3-1.c
${TESTDIR}/conformance/interfaces/mq_close/4-1.c)
endif()
if(NOT CONFIG_LIBC_LOCALTIME)

View file

@ -71,6 +71,7 @@ BLACKSRCS += $(TESTDIR)/conformance/interfaces/pthread_sigmask/18-1.c
BLACKSRCS += $(TESTDIR)/conformance/interfaces/pthread_sigmask/4-1.c
BLACKSRCS += $(TESTDIR)/conformance/interfaces/sigprocmask/4-1.c
ifeq ($(CONFIG_FDCHECK),y)
BLACKSRCS += $(TESTDIR)/conformance/interfaces/mq_close/3-1.c
BLACKSRCS += $(TESTDIR)/conformance/interfaces/mq_close/4-1.c
endif
ifeq ($(CONFIG_LIBC_LOCALTIME),)
@ -247,7 +248,7 @@ ltp-$(LTPS_VERSION).zip:
$(call DOWNLOAD,$(LTP_DOWNLOAD_URL),$(LTPS_VERSION).zip, ltp.zip)
$(LTP_UNPACK): ltp-$(LTPS_VERSION).zip
$(Q) echo "dowload $(LTP_DOWNLOAD_URL)$(LTPS_VERSION).zip"
$(Q) echo "download $(LTP_DOWNLOAD_URL)$(LTPS_VERSION).zip"
$(Q) unzip -o ltp.zip
$(Q) rm -f ltp.zip
$(Q) mv ltp-$(LTPS_VERSION) $(LTP_UNPACK)