From 71779a69e0b5bfcd1efbd95609cf560632c17cb8 Mon Sep 17 00:00:00 2001 From: Mikhail Voytenko Date: Fri, 3 Dec 2010 17:15:07 +0100 Subject: fwk162: #i115836# avoid crash --- unotools/source/ucbhelper/ucblockbytes.cxx | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) (limited to 'unotools') diff --git a/unotools/source/ucbhelper/ucblockbytes.cxx b/unotools/source/ucbhelper/ucblockbytes.cxx index f21855d20aed..9f4c39b397e1 100644 --- a/unotools/source/ucbhelper/ucblockbytes.cxx +++ b/unotools/source/ucbhelper/ucblockbytes.cxx @@ -1538,7 +1538,16 @@ ErrCode UcbLockBytes::Flush() const Reference xOutputStream = getOutputStream_Impl(); if ( !xOutputStream.is() ) return ERRCODE_IO_CANTWRITE; - xOutputStream->flush(); + + try + { + xOutputStream->flush(); + } + catch( Exception ) + { + return ERRCODE_IO_CANTWRITE; + } + return ERRCODE_NONE; } -- cgit v1.2.3