[Mono-bugs] [Bug 82764][Min] New - gmcs/mcs/AssemblyBuilder: native resource file must be writeable

bugzilla-daemon at bugzilla.ximian.com bugzilla-daemon at bugzilla.ximian.com
Sun Sep 9 11:03:56 EDT 2007

Please do not reply to this email- if you want to comment on the bug, go to the
URL shown below and enter your comments there.

Changed by andyhume32 at yahoo.co.uk.


--- shadow/82764	2007-09-09 11:03:56.000000000 -0400
+++ shadow/82764.tmp.9402	2007-09-09 11:03:56.000000000 -0400
@@ -0,0 +1,53 @@
+Bug#: 82764
+Product: Mono: Compilers
+Version: 1.2
+OS Details: 
+Status: NEW   
+Priority: Minor
+Component: C#
+AssignedTo: rharinath at novell.com                            
+ReportedBy: andyhume32 at yahoo.co.uk               
+QAContact: mono-bugs at ximian.com
+TargetMilestone: ---
+Summary: gmcs/mcs/AssemblyBuilder: native resource file must be writeable
+Similar to bug 82617 "Wrong file permissions used for the '-
+win32icon:foo.ico' command line parameter" (and to bug 81669 "Icon..ctor
+(String filename) needs Write access to the file").
+Repro: compile any program with /win32res:Icon.ico where Icon.ico is read-
+only.  See:
+$ gmcs HelloWorld.cs -pkg:dotnet /win32res:Icon1.ico
+Unhandled Exception: System.UnauthorizedAccessException: Access to the 
+path "d:\Temp\Icon1.ico" is denied.
+  at System.IO.FileStream..ctor (System.String path, FileMode mode, 
+FileAccess access, FileShare share, Int32 bufferSize, Boolean anonymous, 
+FileOptions options) [0x00000]
+  at System.IO.FileStream..ctor (System.String path, FileMode mode) 
+  at (wrapper remoting-invoke-with-check) System.IO.FileStream:.ctor 
+  at System.Reflection.Emit.AssemblyBuilder.DefineUnmanagedResource 
+(System.String resourceFileName) [0x00000]
+  at Mono.CSharp.Driver.MainDriver (System.String[] args) [0x00000]
+  at Mono.CSharp.Driver.Main (System.String[] args) [0x00000]
+Note the stack trace is (as expected) different from the issue in 82617 --
+ it is 11 levels deep, and the fault there is in method 
+The fix to this one is the same as there, but this time in method 
+(After this, of the five issues listed in my comment to 82617, only 
+mcs/class/ByteFX.Data/mysqlclient/Driver.cs remains unmodified).

More information about the mono-bugs mailing list