]> git.mxchange.org Git - simgear.git/blobdiff - simgear/structure/exception.cxx
Mathias Fröhlich:
[simgear.git] / simgear / structure / exception.cxx
index d7c83b08a3bb9636d88894a4bbe20757746880a8..af9be51648c1af0a089b85170668f0442cea5959 100644 (file)
@@ -229,8 +229,11 @@ const string
 sg_io_exception::getFormattedMessage () const
 {
   string ret = getMessage();
-  ret += "\n at ";
-  ret += getLocation().asString();
+  string loc = getLocation().asString();
+  if (loc.length()) {
+    ret += "\n at ";
+    ret += loc;
+  }
   return ret;
 }