Increase internal vortex connection reference counting.
Because Vortex Library design, several on going threads shares references to the same connection for several purposes.
Connection reference counting allows to every on going thread to notify the system that connection reference is no longer be used so, if the reference counting reach a zero value, connection resources will be deallocated.
While using the Vortex Library is not required to use this function especially for those applications which are built on top of a profile which is layered on Vortex Library.
This is because connection handling is through functions such vortex_connection_new and vortex_connection_close.
However, while implementing new profiles these function becomes a key concept to ensure the profile implementation don't get lost connection references.
Keep in mind that using this function implied to use vortex_connection_unref function in all code path implemented. For each call to vortex_connection_ref it should exist a call to vortex_connection_unref. Failing on doing this will cause either memory leak or memory corruption because improper connection deallocations.
|connection ||the connection to operate. |
|who ||who have increased the reference. |