diff --git a/Base/src/Image.cpp b/Base/src/Image.cpp index 0826060..ea18b36 100644 --- a/Base/src/Image.cpp +++ b/Base/src/Image.cpp @@ -93,7 +93,9 @@ Image::Image(const Image &other) , m_Height(other.m_Height) , m_Pixels(new PixelType[GetNumPixels()]) { - memcpy(m_Pixels, other.m_Pixels, GetNumPixels() * sizeof(PixelType)); + if(other.m_Pixels) { + memcpy(m_Pixels, other.m_Pixels, GetNumPixels() * sizeof(PixelType)); + } } template