[C#] DLL이 Debug인지 Release인지 판단방법 - 부정확

Posted on 2018. 2. 9. 15:32
Filed Under C#



출처:

http://smallbutdeep.tistory.com/253

http://dave-black.blogspot.kr/2011/12/how-to-tell-if-assembly-is-debug-or.html



▼Debug

// --- 다음 사용자 지정 특성이 자동으로 추가됩니다. 주석 처리를 제거하지 마십시오. -------

//  .custom instance void [mscorlib]System.Diagnostics.DebuggableAttribute::.ctor(valuetype [mscorlib]System.Diagnostics.DebuggableAttribute/DebuggingModes) = ( 01 00 07 01 00 00 00 00 )


▼Release

// --- 다음 사용자 지정 특성이 자동으로 추가됩니다. 주석 처리를 제거하지 마십시오. -------

//  .custom instance void [mscorlib]System.Diagnostics.DebuggableAttribute::.ctor(valuetype [mscorlib]System.Diagnostics.DebuggableAttribute/DebuggingModes) = ( 01 00 02 00 00 00 00 00 ) 


 

▶ 결론적으로 4번째 바이트(DebuggableAttribute.DebuggingModes.DisableOptimizations)

0 = DebugMode

1 = ReleaseMode


반응형

About

by 쑤기c

반응형