summaryrefslogtreecommitdiff
path: root/TAO/tao/Compression
diff options
context:
space:
mode:
authorJohnny Willemsen <jwillemsen@remedy.nl>2009-02-14 07:37:38 +0000
committerJohnny Willemsen <jwillemsen@remedy.nl>2009-02-14 07:37:38 +0000
commit7dc27cfeaf6c0f8fe73cf5d864e32da15eae61d3 (patch)
tree30a0af1c3b65185412562828163cc4585a1fe29d /TAO/tao/Compression
parent9b446b2a75b74d3e075a7c06daf0f9e5149c287e (diff)
downloadATCD-7dc27cfeaf6c0f8fe73cf5d864e32da15eae61d3.tar.gz
Sat Feb 14 07:36:39 UTC 2009 Johnny Willemsen <jwillemsen@remedy.nl>
* tao/Compression/lzo/LzoCompressor.cpp: * tao/Compression/zlib/ZlibCompressor.cpp: Fixed compile errors
Diffstat (limited to 'TAO/tao/Compression')
-rw-r--r--TAO/tao/Compression/lzo/LzoCompressor.cpp4
-rw-r--r--TAO/tao/Compression/zlib/ZlibCompressor.cpp9
2 files changed, 6 insertions, 7 deletions
diff --git a/TAO/tao/Compression/lzo/LzoCompressor.cpp b/TAO/tao/Compression/lzo/LzoCompressor.cpp
index e84b7d931e8..c67b4a25ec8 100644
--- a/TAO/tao/Compression/lzo/LzoCompressor.cpp
+++ b/TAO/tao/Compression/lzo/LzoCompressor.cpp
@@ -39,7 +39,7 @@ LzoCompressor::compress (
if (retval != LZO_E_OK)
{
- throw ::Compression::CompressionException (retval);
+ throw ::Compression::CompressionException (retval, "");
}
else
{
@@ -66,7 +66,7 @@ LzoCompressor::decompress (
if (retval != LZO_E_OK)
{
- throw ::Compression::CompressionException (retval);
+ throw ::Compression::CompressionException (retval, "");
}
else
{
diff --git a/TAO/tao/Compression/zlib/ZlibCompressor.cpp b/TAO/tao/Compression/zlib/ZlibCompressor.cpp
index 45c27e26765..85ce653b9a5 100644
--- a/TAO/tao/Compression/zlib/ZlibCompressor.cpp
+++ b/TAO/tao/Compression/zlib/ZlibCompressor.cpp
@@ -23,8 +23,8 @@ ZlibCompressor::compress (
::Compression::Buffer & target
)
{
- uLongf max_length =
- static_cast <uLongf> (source.length () * 1.1) + TAO_GIOP_MESSAGE_HEADER_LEN;
+ uLongf max_length =
+ static_cast <uLongf> (source.length () * 1.1);
target.length (static_cast <CORBA::ULong> (max_length));
int const retval = ::compress2 (reinterpret_cast <Bytef*>(target.get_buffer ()),
@@ -35,14 +35,13 @@ ZlibCompressor::compress (
if (retval != Z_OK)
{
- throw ::Compression::CompressionException (retval,
- CORBA::string_dup(""));
+ throw ::Compression::CompressionException (retval, "");
}
else
{
target.length (static_cast <CORBA::ULong> (max_length));
}
-
+
// Update statistics for this compressor
this->update_stats (source.length (), target.length ());
}