mirror of
https://github.com/Ryujinx/Opentk.git
synced 2025-01-25 19:11:05 +00:00
Enable InitLocals to make peverify happy
This commit is contained in:
parent
e48a624003
commit
fb99c7d7a1
|
@ -324,6 +324,12 @@ namespace OpenTK.Rewrite
|
||||||
// return
|
// return
|
||||||
il.Emit(OpCodes.Ret);
|
il.Emit(OpCodes.Ret);
|
||||||
|
|
||||||
|
if (body.Variables.Count > 0)
|
||||||
|
{
|
||||||
|
// Required for verifiable executables
|
||||||
|
// (otherwise peverify complains bitterly)
|
||||||
|
body.InitLocals = true;
|
||||||
|
}
|
||||||
body.OptimizeMacros();
|
body.OptimizeMacros();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue