Skip to content

Commit b71efce

Browse files
authored
fixes cache collisions in the resource manager (#2544)
Co-authored-by: harryob <55142896+harryob@users.noreply.github.com>
1 parent 86fb4e8 commit b71efce

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

OpenDreamClient/Resources/DreamResourceManager.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,7 @@ private void RxBrowseResource(MsgBrowseResource message) {
9898
}
9999

100100
private byte[] GetFileHash(ResPath path) {
101-
var stream = _resourceManager.UserData.OpenRead(path);
101+
using var stream = _resourceManager.UserData.OpenRead(path);
102102
Span<byte> filebytes = new(new byte[stream.Length]);
103103
stream.ReadToEnd(filebytes);
104104
return CryptoGenericHashBlake2B.Hash(32, filebytes, ReadOnlySpan<byte>.Empty);

0 commit comments

Comments
 (0)