diff options
author | Mike Kaganski <mike.kaganski@collabora.com> | 2018-10-28 03:09:02 +0300 |
---|---|---|
committer | Mike Kaganski <mike.kaganski@collabora.com> | 2018-10-28 08:23:32 +0100 |
commit | 36880d76299e913761f03bbde1b6ca6bea393b5a (patch) | |
tree | 05a880ec60124a405a2d817b2598f23a2bbba423 /ucb | |
parent | 85985a6ad85ebd3debf63e286dacbe5945178796 (diff) |
tdf#120703 PVS: V547 Expression is always true/false
Change-Id: I1e5098e11f1e5e2f7c5518ea05c57512f58b585b
Reviewed-on: https://gerrit.libreoffice.org/62464
Tested-by: Jenkins
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
Diffstat (limited to 'ucb')
-rw-r--r-- | ucb/source/ucp/ftp/ftpcontent.cxx | 18 |
1 files changed, 2 insertions, 16 deletions
diff --git a/ucb/source/ucp/ftp/ftpcontent.cxx b/ucb/source/ucp/ftp/ftpcontent.cxx index 5279a74aa1b2..67767892b816 100644 --- a/ucb/source/ucp/ftp/ftpcontent.cxx +++ b/ucb/source/ucp/ftp/ftpcontent.cxx @@ -450,10 +450,9 @@ Any SAL_CALL FTPContent::execute( const Command& aCommand, else if(xOutputStream.is()) { Reference<XInputStream> xStream( new ucbhelper::FdInputStream(m_aFTPURL.open())); - Sequence<sal_Int8> byte_seq(4096); - sal_Int32 n = 1000; // value does not matter here for (;;) { - n = xStream->readBytes(byte_seq,4096); + Sequence<sal_Int8> byte_seq(4096); + sal_Int32 n = xStream->readBytes(byte_seq, 4096); if (n == 0) { break; } @@ -469,19 +468,6 @@ Any SAL_CALL FTPContent::execute( const Command& aCommand, } } - if(n) { - Sequence<Any> seq(1); - PropertyValue value; - value.Name = "Uri"; - value.Handle = -1; - value.Value <<= m_aFTPURL.ident(false,false); - value.State = PropertyState_DIRECT_VALUE; - seq[0] <<= value; - ucbhelper::cancelCommandExecution( - IOErrorCode_UNKNOWN, - seq, - Environment); - } } else { aRet <<= UnsupportedDataSinkException( |