Function tarantool_rust_module::box_tuple_ref [] [src]

pub unsafe extern "C" fn box_tuple_ref(tuple: *mut BoxTuple) -> c_int

Increase the reference counter of tuple.

Tuples are reference counted. All functions that return tuples guarantee that the last returned tuple is refcounted internally until the next call to API function that yields or returns another tuple.

You should increase the reference counter before taking tuples for long processing in your code. Such tuples will not be garbage collected even if another fiber remove they from space. After processing please decrement the reference counter using box_tuple_unref(), otherwise the tuple will leak.

\param tuple a tuple \retval -1 on error (check box_error_last()) \retval 0 on success \sa box_tuple_unref()