diff options
author | David Tardon <dtardon@redhat.com> | 2018-03-24 16:32:04 +0100 |
---|---|---|
committer | David Tardon <dtardon@redhat.com> | 2018-03-24 16:35:05 +0100 |
commit | cf5bfaf2991c0c0ef37d2968ff2cf756b0b02089 (patch) | |
tree | 18c38a8cd0dd4f0be65bc5d40c2e9ed4f56217ed | |
parent | e63456225d2953fb9dab8607fb74776a7eb7725f (diff) |
these functions cannot throw any exception
-rw-r--r-- | src/lib/SW602MemoryStream.cpp | 12 |
1 files changed, 2 insertions, 10 deletions
diff --git a/src/lib/SW602MemoryStream.cpp b/src/lib/SW602MemoryStream.cpp index 550e4a5..c10faf0 100644 --- a/src/lib/SW602MemoryStream.cpp +++ b/src/lib/SW602MemoryStream.cpp @@ -59,7 +59,7 @@ librevenge::RVNGInputStream *SW602MemoryStream::getSubStreamById(unsigned) return 0; } -const unsigned char *SW602MemoryStream::read(unsigned long numBytes, unsigned long &numBytesRead) try +const unsigned char *SW602MemoryStream::read(unsigned long numBytes, unsigned long &numBytesRead) { numBytesRead = 0; @@ -75,12 +75,8 @@ const unsigned char *SW602MemoryStream::read(unsigned long numBytes, unsigned lo numBytesRead = numBytes; return m_data + oldPos; } -catch (...) -{ - return 0; -} -int SW602MemoryStream::seek(const long offset, librevenge::RVNG_SEEK_TYPE seekType) try +int SW602MemoryStream::seek(const long offset, librevenge::RVNG_SEEK_TYPE seekType) { long pos = 0; switch (seekType) @@ -104,10 +100,6 @@ int SW602MemoryStream::seek(const long offset, librevenge::RVNG_SEEK_TYPE seekTy m_pos = pos; return 0; } -catch (...) -{ - return -1; -} long SW602MemoryStream::tell() { |