I have an application that uses a 3rd party component. This component references a particular dll, say X. My application is installed on 2 different machines, say A and B. A has 5 X.dll in the Winsxs folder, differing in their minor versions. B has 3 X.dll in the Winsxs folder, again differing in their minor versions.
My application runs fine on machine B. On machine A, it randomly throws an error - "Attempted to read or write protected memory". The stack trace shows that the error is thrown by the 3rd party component. How should I go about solving this? Since I have no control over the component, I am trying to play with its dependencies. Can I rename/delete dlls from machine A to make them the same as machine B? All other machine and OS configurations are the same for both these machines. I cannot determine any other approach to solve this problem. Please help.