/* Function for claiming and activating a write buffer record.  */
static void write_buffer_record_get(pdb_buffer_record_t **pp_write_buffer_record, pm_peer_id_t peer_id, pm_peer_data_id_t data_id)
/* Function for claiming and activating a write buffer record.  */
static void write_buffer_record_get(pdb_buffer_record_t **pp_write_buffer_record, pm_peer_id_t peer_id, pm_peer_data_id_t data_id)
{
    if (pp_write_buffer_record == NULL)
    {
        return;
    }
    *pp_write_buffer_record = write_buffer_record_find_unused();
    if (*pp_write_buffer_record == NULL)
    {
        return;
    }
    (*pp_write_buffer_record)->peer_id = peer_id;
    (*pp_write_buffer_record)->data_id = data_id;
}