Don't report M_RDWR as "generic"
authorMikko Rasa <tdb@tdb.fi>
Thu, 27 Sep 2012 20:45:34 +0000 (23:45 +0300)
committerMikko Rasa <tdb@tdb.fi>
Thu, 27 Sep 2012 20:45:34 +0000 (23:45 +0300)
source/io/mode.cpp

index 71d956bc10fb18ce804c6fe61f089ff82d268233..c945d0265d6f2768f79755c7a36388c1eaa27372 100644 (file)
@@ -6,7 +6,10 @@ namespace Msp {
 namespace IO {
 
 invalid_access::invalid_access(Mode m):
-       logic_error(m==M_READ ? "read" : m==M_WRITE ? "write" : "generic")
+       logic_error(m==M_READ ? "read" :
+               m==M_WRITE ? "write" :
+               m==M_RDWR ? "read-write" :
+               "generic")
 { }
 
 } // namespace IO