Program hænger/crasher .. ressoucer
Hej,Jeg har lidt problemer med, at mit program hænger/crasher sådan hver eller hver anden dag. Samtidig kommer der en fejl "kunne ikke blabla pga manglende ressourcer".
Jeg har kørt en code analysis, som sagde jeg manglede en .Dispose(); hist og her.. bl.a. på et StreamWriter og SqlConnection objekt.. så det kunne jo godt være det.
Men jeg får også en del af fejl som disse i code analysis.. Har det nogen betydning i dette tilfælde, eller er det bare "larm"?
CA2122 : Microsoft.Security : 'MyApp.DoCopyFiles()' calls into 'Process.Start(ProcessStartInfo)' which has a LinkDemand. By making this call, 'Process.Start(ProcessStartInfo)' is indirectly exposed to user code. Review the following call stack that might expose a way to circumvent security protection:
->'MyApp.DoCopyFiles()'
->'MyApp.DoCopyFiles()'
CA2122 : Microsoft.Security : 'MyApp.DoCopyFiles()' calls into 'Process.WaitForExit()' which has a LinkDemand. By making this call, 'Process.WaitForExit()' is indirectly exposed to user code. Review the following call stack that might expose a way to circumvent security protection:
->'MyApp.DoCopyFiles()'
->'MyApp.DoCopyFiles()'
CA2122 : Microsoft.Security : 'MyApp.DoCopyFiles()' calls into 'ProcessStartInfo.Arguments.set(string)' which has a LinkDemand. By making this call, 'ProcessStartInfo.Arguments.set(string)' is indirectly exposed to user code. Review the following call stack that might expose a way to circumvent security protection:
->'MyApp.DoCopyFiles()'
->'MyApp.DoCopyFiles()'
CA2122 : Microsoft.Security : 'MyApp.DoCopyFiles()' calls into 'ProcessStartInfo.CreateNoWindow.set(bool)' which has a LinkDemand. By making this call, 'ProcessStartInfo.CreateNoWindow.set(bool)' is indirectly exposed to user code. Review the following call stack that might expose a way to circumvent security protection:
->'MyApp.DoCopyFiles()'
->'MyApp.DoCopyFiles()'
CA2122 : Microsoft.Security : 'MyApp.IsProcessOpen(string)' calls into 'Process.GetProcesses()' which has a LinkDemand. By making this call, 'Process.GetProcesses()' is indirectly exposed to user code. Review the following call stack that might expose a way to circumvent security protection:
->'MyApp.IsProcessOpen(string)'
->'MyApp.IsProcessOpen(string)'