Fix for "add object" crash in editor

This commit is contained in:
Justin Marshall
2020-06-06 17:45:13 -07:00
parent 4ae1728633
commit c4566e3062
+3
View File
@@ -1921,6 +1921,9 @@ BOOL __cdecl Linear_Scale_To_Linear(void *this_object, void *dest, int src_x, in
GraphicViewPortClass* viewportClass = (GraphicViewPortClass*)this_object;
GraphicViewPortClass* destViewportClass = (GraphicViewPortClass*)dest;
if (destViewportClass->Get_Graphic_Buffer()->Get_Buffer() == NULL)
return false;
byte* viewportBuffer = ((byte*)viewportClass->Get_Graphic_Buffer()->Get_Buffer());
// Scale the GraphicViewPortClass to dest_x, dest_y