How to clean a json object created by “json_object_new_string”?

前端 未结 1 1159
有刺的猬
有刺的猬 2021-01-19 09:48

I have the following code and I want to clean a json object created by json_object_new_string().

#include 
#include 

        
相关标签:
1条回答
  • 2021-01-19 10:35

    json_object_put will free everything referenced by the object. So yes, it's sufficient to use that function on jobj to free the whole object.

    0 讨论(0)
提交回复
热议问题