Skip to content

Commit 748e32a

Browse files
committed
Fix gcc12 build warning: GmmMultiAdapterULT.cpp:139:27: warning: array subscript 30 is above array bounds of ‘PLATFORM [9][3]’ {aka ‘PLATFORM_STR [9][3]’}
1 parent 506c8e1 commit 748e32a

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

Source/GmmLib/ULT/GmmMultiAdapterULT.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -133,6 +133,7 @@ void MACommonULT::UnLoadGmmDll(uint32_t AdapterIdx, uint32_t CountIdx)
133133

134134
void MACommonULT::GmmInitModule(uint32_t AdapterIdx, uint32_t CountIdx)
135135
{
136+
ASSERT_TRUE(AdapterIdx < MAX_NUM_ADAPTERS);
136137
GMM_STATUS Status = GMM_SUCCESS;
137138
ADAPTER_BDF AdapterBDF = GetAdapterBDF(AdapterIdx);
138139
GfxPlatform[AdapterIdx][CountIdx].eProductFamily = GetProductFamily(AdapterIdx);

0 commit comments

Comments
 (0)