projects
/
platform
/
upstream
/
dotnet
/
runtime.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
0f1920d
)
Always call CloseHandle in AsmMan::EmitManifest (#50372)
author
Omair Majid
<omajid@redhat.com>
Tue, 18 May 2021 00:45:50 +0000
(20:45 -0400)
committer
GitHub
<noreply@github.com>
Tue, 18 May 2021 00:45:50 +0000
(17:45 -0700)
Unless it's an ERROR_INVALID_HANDLE.
Otherwise, we can leak the file handle.
src/coreclr/ilasm/asmman.cpp
patch
|
blob
|
history
diff --git
a/src/coreclr/ilasm/asmman.cpp
b/src/coreclr/ilasm/asmman.cpp
index
87e79e5
..
2e4b98b
100644
(file)
--- a/
src/coreclr/ilasm/asmman.cpp
+++ b/
src/coreclr/ilasm/asmman.cpp
@@
-1000,8
+1000,9
@@
HRESULT AsmMan::EmitManifest()
m_fMResNew[m_dwMResNum] = TRUE;
m_dwMResNum++;
}
- CloseHandle(hFile);
}
+
+ CloseHandle(hFile);
}
}
if(fOK || ((Assembler*)m_pAssembler)->OnErrGo)