Skip to content

Commit 1e6ac94

Browse files
committed
Correct the comment of row_vers_impl_x_locked()
1 parent bdeb27a commit 1e6ac94

File tree

2 files changed

+35
-34
lines changed

2 files changed

+35
-34
lines changed

storage/innobase/include/row0vers.h

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
/*****************************************************************************
22
33
Copyright (c) 1997, 2016, Oracle and/or its affiliates. All Rights Reserved.
4+
Copyright (c) 2017, MariaDB Corporation.
45
56
This program is free software; you can redistribute it and/or modify it under
67
the terms of the GNU General Public License as published by the Free Software
@@ -38,19 +39,18 @@ Created 2/6/1997 Heikki Tuuri
3839
// Forward declaration
3940
class ReadView;
4041

41-
/*****************************************************************//**
42-
Finds out if an active transaction has inserted or modified a secondary
42+
/** Determine if an active transaction has inserted or modified a secondary
4343
index record.
44-
@return 0 if committed, else the active transaction id;
45-
NOTE that this function can return false positives but never false
46-
negatives. The caller must confirm all positive results by calling
47-
trx_is_active() while holding lock_sys->mutex. */
44+
@param[in] rec secondary index record
45+
@param[in] index secondary index
46+
@param[in] offsets rec_get_offsets(rec, index)
47+
@return the active transaction; trx_release_reference() must be invoked
48+
@retval NULL if the record was committed */
4849
trx_t*
4950
row_vers_impl_x_locked(
50-
/*===================*/
51-
const rec_t* rec, /*!< in: record in a secondary index */
52-
dict_index_t* index, /*!< in: the secondary index */
53-
const ulint* offsets);/*!< in: rec_get_offsets(rec, index) */
51+
const rec_t* rec,
52+
dict_index_t* index,
53+
const ulint* offsets);
5454

5555
/*****************************************************************//**
5656
Finds out if we must preserve a delete marked earlier version of a clustered

storage/innobase/row/row0vers.cc

Lines changed: 25 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
/*****************************************************************************
22
33
Copyright (c) 1997, 2016, Oracle and/or its affiliates. All Rights Reserved.
4-
Copyright (c) 2017, MariaDB Corporation
4+
Copyright (c) 2017, MariaDB Corporation.
55
66
This program is free software; you can redistribute it and/or modify it under
77
the terms of the GNU General Public License as published by the Free Software
@@ -63,23 +63,25 @@ row_vers_non_vc_match(
6363
const dtuple_t* ientry,
6464
mem_heap_t* heap,
6565
ulint* n_non_v_col);
66-
/*****************************************************************//**
67-
Finds out if an active transaction has inserted or modified a secondary
66+
/** Determine if an active transaction has inserted or modified a secondary
6867
index record.
69-
@return 0 if committed, else the active transaction id;
70-
NOTE that this function can return false positives but never false
71-
negatives. The caller must confirm all positive results by calling
72-
trx_is_active() while holding lock_sys->mutex. */
68+
@param[in] clust_rec clustered index record
69+
@param[in] clust_index clustered index
70+
@param[in] rec secondary index record
71+
@param[in] index secondary index
72+
@param[in] offsets rec_get_offsets(rec, index)
73+
@param[in,out] mtr mini-transaction
74+
@return the active transaction; trx_release_reference() must be invoked
75+
@retval NULL if the record was committed */
7376
UNIV_INLINE
7477
trx_t*
7578
row_vers_impl_x_locked_low(
76-
/*=======================*/
77-
const rec_t* clust_rec, /*!< in: clustered index record */
78-
dict_index_t* clust_index, /*!< in: the clustered index */
79-
const rec_t* rec, /*!< in: secondary index record */
80-
dict_index_t* index, /*!< in: the secondary index */
81-
const ulint* offsets, /*!< in: rec_get_offsets(rec, index) */
82-
mtr_t* mtr) /*!< in/out: mini-transaction */
79+
const rec_t* clust_rec,
80+
dict_index_t* clust_index,
81+
const rec_t* rec,
82+
dict_index_t* index,
83+
const ulint* offsets,
84+
mtr_t* mtr)
8385
{
8486
trx_id_t trx_id;
8587
ibool corrupt;
@@ -325,19 +327,18 @@ row_vers_impl_x_locked_low(
325327
DBUG_RETURN(trx);
326328
}
327329

328-
/*****************************************************************//**
329-
Finds out if an active transaction has inserted or modified a secondary
330+
/** Determine if an active transaction has inserted or modified a secondary
330331
index record.
331-
@return 0 if committed, else the active transaction id;
332-
NOTE that this function can return false positives but never false
333-
negatives. The caller must confirm all positive results by calling
334-
trx_is_active() while holding lock_sys->mutex. */
332+
@param[in] rec secondary index record
333+
@param[in] index secondary index
334+
@param[in] offsets rec_get_offsets(rec, index)
335+
@return the active transaction; trx_release_reference() must be invoked
336+
@retval NULL if the record was committed */
335337
trx_t*
336338
row_vers_impl_x_locked(
337-
/*===================*/
338-
const rec_t* rec, /*!< in: record in a secondary index */
339-
dict_index_t* index, /*!< in: the secondary index */
340-
const ulint* offsets)/*!< in: rec_get_offsets(rec, index) */
339+
const rec_t* rec,
340+
dict_index_t* index,
341+
const ulint* offsets)
341342
{
342343
mtr_t mtr;
343344
trx_t* trx;

0 commit comments

Comments
 (0)