* roottypes.cs: Rename from tree.cs.
[mono.git] / mcs / class / System / System.CodeDom.Compiler / IndentedTextWriter.cs
index c823093aafeaa5f4988dfcdd05fcd4e3646b6086..239d49b18b17a1d1069a772abcc9a6e456c43a4f 100644 (file)
@@ -5,8 +5,7 @@
 //   Daniel Stodden (stodden@in.tum.de)
 //
 // (C) 2002 Ximian, Inc.
-//
-
+// Copyright (C) 2005 Novell, Inc (http://www.novell.com)
 //
 // Permission is hereby granted, free of charge, to any person obtaining
 // a copy of this software and associated documentation files (the
 //
 
 using System.IO;
+using System.Security.Permissions;
 using System.Text;
 
 namespace System.CodeDom.Compiler {
        
+       [PermissionSet (SecurityAction.LinkDemand, Unrestricted = true)]
+       [PermissionSet (SecurityAction.InheritanceDemand, Unrestricted = true)]
        public class IndentedTextWriter
                : TextWriter
        {
@@ -78,6 +80,9 @@ namespace System.CodeDom.Compiler {
                                return indent;
                        }
                        set {
+                               if (value < 0) {
+                                       value = 0;
+                               }
                                indent = value;
                        }
                }