Skip to main content

All Questions

Filter by
Sorted by
Tagged with
0 votes
1 answer
1k views

Issue with returning MemoryStream and memory leak [duplicate]

I am having issues with disposing MemoryStream in methods like below. Can you guide on which one to follow and why? public MemoryStream FetchImageStream() { try { MemoryStream ...
Akon's user avatar
  • 272
0 votes
3 answers
1k views

How to detect a memory leak

I have doubts that this part of code causes memory leak: public FileResult ShowCroppedImage(int id, int size) { string path = "~/Uploads/Photos/"; string sourceFile = Server....
ilija veselica's user avatar