diff --git a/test/resource/amssystemtestability/abilitySrc/amsDataSystemTestA/src/ams_st_data_ability_data_a.cpp b/test/resource/amssystemtestability/abilitySrc/amsDataSystemTestA/src/ams_st_data_ability_data_a.cpp index 45f840465dbb97fb29ef86af4dd6a3731a353ff2..e812204741936176c6521c5e98a6b0d3a5d4013e 100644 --- a/test/resource/amssystemtestability/abilitySrc/amsDataSystemTestA/src/ams_st_data_ability_data_a.cpp +++ b/test/resource/amssystemtestability/abilitySrc/amsDataSystemTestA/src/ams_st_data_ability_data_a.cpp @@ -175,6 +175,7 @@ int AmsStDataAbilityDataA::OpenFile(const Uri &uri, const std::string &mode) fd = fileno(fd1); APP_LOGI("--------------------------------AmsStDataAbilityDataA fd: %{public}d", fd); PublishEvent(abilityEventName, ABILITY_DATA_A_CODE, "OpenFile"); + fclose(fd1); return fd; }