diff options
Diffstat (limited to 'mcs/class/corlib/System.IO/File.cs')
-rw-r--r-- | mcs/class/corlib/System.IO/File.cs | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/mcs/class/corlib/System.IO/File.cs b/mcs/class/corlib/System.IO/File.cs index 3dcf8213759..c45dea6aecb 100644 --- a/mcs/class/corlib/System.IO/File.cs +++ b/mcs/class/corlib/System.IO/File.cs @@ -70,7 +70,7 @@ namespace System.IO if (dest.Trim () == "" || dest.IndexOfAny (Path.InvalidPathChars) != -1) throw new ArgumentException ("dest"); if (!Exists (src)) - throw new FileNotFoundException (src + " does not exist", src); + throw new FileNotFoundException (src + " does not exist"); if ((GetAttributes(src) & FileAttributes.Directory) == FileAttributes.Directory){ throw new ArgumentException(src + " is a directory"); @@ -261,11 +261,9 @@ namespace System.IO if (dest.Trim () == "" || dest.IndexOfAny (Path.InvalidPathChars) != -1) throw new ArgumentException ("dest"); if (!MonoIO.Exists (src, out error)) - throw new FileNotFoundException (src + " does not exist", src); + throw new FileNotFoundException (src + " does not exist"); if (MonoIO.ExistsDirectory (dest, out error)) throw new IOException (dest + " is a directory"); - if (MonoIO.Exists (dest, out error)) - throw new IOException (dest + " already exists"); string DirName; DirName = Path.GetDirectoryName(src); |