From d0b82bc3bc58e6382a70e18bc14f8f7bcdf165d0 Mon Sep 17 00:00:00 2001 From: Santosh Puranik Date: Fri, 28 Oct 2016 02:24:27 -0500 Subject: Fix fapi2::Target creation on the SBE -- Made plat target c'tor explicit so that fapi2::Target can't be constructed with a uint32_t Change-Id: Ibcfa3bffe41afdcef7256c3a65ffee5ef23fc76b Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/31943 Tested-by: Jenkins Server Tested-by: FSP CI Jenkins Reviewed-by: Sachin Gupta --- src/hwpf/include/plat/plat_target.H | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/hwpf') diff --git a/src/hwpf/include/plat/plat_target.H b/src/hwpf/include/plat/plat_target.H index bf7bcad3..14df2ab8 100644 --- a/src/hwpf/include/plat/plat_target.H +++ b/src/hwpf/include/plat/plat_target.H @@ -90,7 +90,7 @@ namespace fapi2 /// /// @param i_value Value to instantiate handle with /// - plat_target_handle(uint32_t i_value = 0):value(i_value) {} + explicit plat_target_handle(uint32_t i_value = 0):value(i_value) {} /// /// @brief Get the fapi2::TargetType for this target @@ -210,7 +210,7 @@ namespace fapi2 { static_assert((MULTICAST != true) || (K == TARGET_TYPE_PROC_CHIP), "Only PROC_CHIP types can be multicast"); - plat_target_handle_t l_handle = 0; + plat_target_handle_t l_handle; if(MULTICAST == true) { -- cgit v1.2.1