]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Improve error message of ExcFileNotOpen 11012/head
authorPeter Munch <peterrmuench@gmail.com>
Tue, 6 Oct 2020 09:03:11 +0000 (11:03 +0200)
committerPeter Munch <peterrmuench@gmail.com>
Tue, 6 Oct 2020 09:04:35 +0000 (11:04 +0200)
include/deal.II/base/exceptions.h

index 171411eb079852f2017542e695b28f07931e2e6f..588fa60d9d4b4e4ac745e3cd2df69dbad68dd6f3 100644 (file)
@@ -743,7 +743,19 @@ namespace StandardExceptions
    */
   DeclException1(ExcFileNotOpen,
                  std::string,
-                 << "Could not open file " << arg1 << ".");
+                 << "Could not open file " << arg1
+                 << "."
+                    "\n\n"
+                    "If this happens during an operation that tries to read "
+                    "data: you may be "
+                    "trying to read from a file that doesn't exist or that is "
+                    "not readable given its file permissions."
+                    "\n\n"
+                    "If this happens during an operation that tries to write "
+                    "data: you may be trying to write to a file to which file "
+                    "or directory permissions do not allow you to write. A "
+                    "typical example is where you specify an output file in "
+                    "a directory that does not exist.");
 
   /**
    * Exception denoting a part of the library or application program that has

In the beginning the Universe was created. This has made a lot of people very angry and has been widely regarded as a bad move.

Douglas Adams


Typeset in Trocchi and Trocchi Bold Sans Serif.