MCPcopy Create free account
hub / github.com/RedisGraph/RedisGraph / SIValue_Free

Function SIValue_Free

src/value.c:828–852  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

826}
827
828void SIValue_Free(SIValue v) {
829 // The free routine only performs work if it owns a heap allocation.
830 if(v.allocation != M_SELF) return;
831
832 switch(v.type) {
833 case T_STRING:
834 rm_free(v.stringval);
835 v.stringval = NULL;
836 return;
837 case T_NODE:
838 case T_EDGE:
839 rm_free(v.ptrval);
840 return;
841 case T_ARRAY:
842 SIArray_Free(v);
843 return;
844 case T_PATH:
845 SIPath_Free(v);
846 return;
847 case T_MAP:
848 Map_Free(v);
849 default:
850 return;
851 }
852}
853

Callers 15

_ParameterFreeCallbackFunction · 0.85
_applyPredicateFiltersFunction · 0.85
FilterTree_applyFiltersFunction · 0.85
extractOriginAndRadiusFunction · 0.85
ResultSet_FreeFunction · 0.85
Group_FreeFunction · 0.85
_RdbLoadSIArrayFunction · 0.85
_RdbLoadSIArrayFunction · 0.85
_RdbLoadSIArrayFunction · 0.85
_RdbLoadSIArrayFunction · 0.85

Calls 4

rm_freeFunction · 0.85
SIArray_FreeFunction · 0.85
SIPath_FreeFunction · 0.85
Map_FreeFunction · 0.85

Tested by 5

test_map_tostringFunction · 0.68
test_numericsFunction · 0.68
test_stringsFunction · 0.68
test_arrayFunction · 0.68
test_setFunction · 0.68