From b67d81a8e57a6601e0bd8620a9d80e03e48a4ba4 Mon Sep 17 00:00:00 2001 From: Andrea Zoli Date: Tue, 24 Jun 2014 11:37:54 +0200 Subject: [PATCH] Fix throw on ByteStream::GetValue(). --- src/ByteStream.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/ByteStream.cpp b/src/ByteStream.cpp index 93a992c..be87b8b 100644 --- a/src/ByteStream.cpp +++ b/src/ByteStream.cpp @@ -18,6 +18,7 @@ #include "ByteStream.h" #include "PacketLibDemo.h" +#include "PacketException.h" #include "Utility.h" #include "lz4.h" #include "lz4hc.h" @@ -228,7 +229,7 @@ long PacketLib::ByteStream::getValue(dword start, word dim) byte b1, b2; if(start >= byteInTheStream) - throw new PacketException("PacketLib::ByteStream::getValue() start greater than the size of the ByteStream"); + throw PacketException("PacketLib::ByteStream::getValue() start greater than the size of the ByteStream", 0); /// only 1 or 2 bytes if(dim == 0 || dim > 2) -- GitLab