Confirmsorteddata
int Confirmsorteddata(t_sorted *sd,int confirm);
Sets or resets bit TY_CONFIRMED in all items of the sorted data.
Parameters:
sd
(in,out) Pointer to the descriptor of sorted data (structure of type t_sorted). This call will fail if sorted data contains no type (was created with flag SDM_NOSIZE)
confirm
(in) Flag that specifies the requested action. If confirm is 0, bit TY_CONFIRMED is removed from all items in the sorted data sd. Otherwise, bit TY_CONFIRMED is set in all data items
Return
values:
Returns 0 on success and -1 on error
This function is useful if one wants to delete many scattered items of sorted data at once. First call Confirmsorteddata(1) to confirm all data. Next, walk data and remove bit TY_CONFIRMED from the items that must be deleted. Finally, call Deletenonconfirmedsorteddata().
Example:
See
also: