L
Lothar Behrens
Hi,
I have developed an update mechanism to pull new files and also update
recently downloaded files by the md5 sum. The recently downloaded
files are from a prior try to update files. This does hopefully reduce
traffic. The problem arises with the following code:
MD5 md5 = MD5.Create();
FileStream fs = new FileStream(file, FileMode.Open);
md5.ComputeHash(fs);
The new file to update has been downloaded previously. Now the old
file (DLL) is still loaded and thus the above code does not work.
How to create a checksum of a file that is loaded in a process?
I think copying the file and do the checksum with the copy is a
solution but not the best.
Thanks
Lothar
I have developed an update mechanism to pull new files and also update
recently downloaded files by the md5 sum. The recently downloaded
files are from a prior try to update files. This does hopefully reduce
traffic. The problem arises with the following code:
MD5 md5 = MD5.Create();
FileStream fs = new FileStream(file, FileMode.Open);
md5.ComputeHash(fs);
The new file to update has been downloaded previously. Now the old
file (DLL) is still loaded and thus the above code does not work.
How to create a checksum of a file that is loaded in a process?
I think copying the file and do the checksum with the copy is a
solution but not the best.
Thanks
Lothar