When you are no longer using the value, you should free it from memory by calling slapi_valueset_free().