c# - Is it possible to patch a dotnet function on the fly -
recently found architect-often-used .net program has implemented function wrongly. patched it using ilspy , reflexil in static way of modifying binaries. however, annoying need patch , remove strongnamecheck again when new minor version releases. (btw, author believes feature instead of bug)
hopefully, program supports assemblies plugin. , target a public non-static member function in public class can directly called plugins. there way patch function on fly?
i use apihook tricks in unmanaged c++ dotnet different thing. in case, want modification still valid after assembly unloads (so more similar patch, not hook).
don't monkey patch code. add functionality code base , call function. or write adapter class wraps underlying assembly, neater.
if author of code thinks it's not bug may in there reasons don't understand , part of number of bug fixes.
Comments
Post a Comment