diff options
author | Ocke Janssen <oj@openoffice.org> | 2001-04-26 12:31:47 +0000 |
---|---|---|
committer | Ocke Janssen <oj@openoffice.org> | 2001-04-26 12:31:47 +0000 |
commit | 7357a27874d42e8cb83d288f5b304b4dc3ecfa39 (patch) | |
tree | 488f9fff6cbe63dc43e828e65608e727a107aca0 /connectivity/source/drivers/file/FConnection.cxx | |
parent | 3e685efa0c60acedf961706f8e290875c2042e43 (diff) |
#85397# insert a better error msg when url is invalid
Diffstat (limited to 'connectivity/source/drivers/file/FConnection.cxx')
-rw-r--r-- | connectivity/source/drivers/file/FConnection.cxx | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/connectivity/source/drivers/file/FConnection.cxx b/connectivity/source/drivers/file/FConnection.cxx index be29f6b91e3f..7f230d574c22 100644 --- a/connectivity/source/drivers/file/FConnection.cxx +++ b/connectivity/source/drivers/file/FConnection.cxx @@ -2,9 +2,9 @@ * * $RCSfile: FConnection.cxx,v $ * - * $Revision: 1.21 $ + * $Revision: 1.22 $ * - * last change: $Author: fs $ $Date: 2001-04-12 15:08:02 $ + * last change: $Author: oj $ $Date: 2001-04-26 13:31:47 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -219,9 +219,15 @@ void OConnection::construct(const ::rtl::OUString& url,const Sequence< PropertyV aError.SQLState = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("S1000")); aError.ErrorCode = 0; aError.Context = static_cast< XConnection* >(this); + SQLException aUrlError; + aUrlError.Message = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Invalid URL: ")); + aUrlError.Message += url; + aError.NextException <<= aUrlError; if (e.Message.getLength()) - aError.NextException <<= SQLException(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("UCB message: ")) += e.Message, aError.Context, ::rtl::OUString(), 0, Any()); - throw SQLException(aError); + { + aUrlError.NextException <<= SQLException(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("UCB message: ")) += e.Message, aError.Context, ::rtl::OUString(), 0, Any()); + } + throw aError; } // if (aFileStat.IsKind(FSYS_KIND_WILD)) |