to check element after Collection::Insert

This commit is contained in:
2023-07-21 10:46:28 +08:00
parent 75c52f0b93
commit 205d246e8a

View File

@@ -127,6 +127,9 @@ namespace hgl
*/ */
bool Collection::Insert(const uint64 offset,const void *element) bool Collection::Insert(const uint64 offset,const void *element)
{ {
if(!element)
return(false);
if(data_count==0) if(data_count==0)
return Add(element); return Add(element);