Browse Source

Fixed OOB bug indxcdia.cpp (#293)

yurido1 8 years ago
parent
commit
8e029bce40
1 changed files with 2 additions and 2 deletions
  1. 2 2
      tools/clang/tools/dxcompiler/dxcdia.cpp

+ 2 - 2
tools/clang/tools/dxcompiler/dxcdia.cpp

@@ -678,8 +678,8 @@ public:
     /* [in] */ DWORD index,
     /* [in] */ DWORD index,
     /* [retval][out] */ TItem **ppItem) {
     /* [retval][out] */ TItem **ppItem) {
     if (index >= m_count)
     if (index >= m_count)
-      return GetItem(index, ppItem);
-    return E_INVALIDARG;
+      return E_INVALIDARG;
+    return GetItem(index, ppItem);
   }
   }
 
 
   virtual HRESULT GetItem(DWORD index, TItem **ppItem) {
   virtual HRESULT GetItem(DWORD index, TItem **ppItem) {