Skip to content

Commit

Permalink
APITemplates.h: add assert
Browse files Browse the repository at this point in the history
  • Loading branch information
1vanK committed Oct 25, 2022
1 parent fe5dc62 commit f7231b8
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions Source/Urho3D/AngelScript/APITemplates.h
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,8 @@ template <class T> CScriptArray* VectorToArray(const Vector<T>& vector, const ch
/// Template function for data buffer to array conversion.
template <class T> CScriptArray* BufferToArray(const T* buffer, asUINT size, const char* arrayName)
{
assert(size <= M_MAX_I32);

Context* context = GetScriptContext();
if (context)
{
Expand Down

0 comments on commit f7231b8

Please sign in to comment.