summaryrefslogtreecommitdiff
path: root/myisam
diff options
context:
space:
mode:
authorunknown <monty@mysql.com>2004-10-06 17:20:39 +0300
committerunknown <monty@mysql.com>2004-10-06 17:20:39 +0300
commitfe46310640b081114f1d9f9be0e3f88f8fd7d926 (patch)
tree619d2edcc173d5aa14588e1fdd33b506ed20373f /myisam
parent95e1c07483005b784aaefa35b5a8597ffb1d3932 (diff)
downloadmariadb-git-fe46310640b081114f1d9f9be0e3f88f8fd7d926.tar.gz
Code cleanups while doing review of pushed code
myisam/mi_locking.c: More comments sql/mysql_priv.h: Change mode to uint (as it's a bitmap) sql/sql_handler.cc: Change mode to uint (as it's a bitmap) Fixed DBUG_PRINT to use same format as other MySQL code
Diffstat (limited to 'myisam')
-rw-r--r--myisam/mi_locking.c32
1 files changed, 18 insertions, 14 deletions
diff --git a/myisam/mi_locking.c b/myisam/mi_locking.c
index 1efd203dc5f..d5212cdee47 100644
--- a/myisam/mi_locking.c
+++ b/myisam/mi_locking.c
@@ -21,19 +21,6 @@
isamdatabase.
*/
-/*
- state.open_count in the .MYI file is used the following way:
- - For the first change of the file in this process it's incremented with
- mi_mark_file_change(). (We have a write lock on the file in this case)
- - In mi_close() it's decremented by _mi_decrement_open_count() if it
- was incremented in the same process.
-
- This mean that if we are the only process using the file, the open_count
- tells us if the MYISAM file wasn't properly closed. (This is true if
- my_disable_locking is set).
-*/
-
-
#include "myisamdef.h"
#ifdef __WIN__
#include <errno.h>
@@ -426,7 +413,24 @@ int _mi_test_if_changed(register MI_INFO *info)
} /* _mi_test_if_changed */
-/* Put a mark in the .MYI file that someone is updating the table */
+/*
+ Put a mark in the .MYI file that someone is updating the table
+
+
+ DOCUMENTATION
+
+ state.open_count in the .MYI file is used the following way:
+ - For the first change of the .MYI file in this process open_count is
+ incremented by mi_mark_file_change(). (We have a write lock on the file
+ when this happens)
+ - In mi_close() it's decremented by _mi_decrement_open_count() if it
+ was incremented in the same process.
+
+ This mean that if we are the only process using the file, the open_count
+ tells us if the MYISAM file wasn't properly closed. (This is true if
+ my_disable_locking is set).
+*/
+
int _mi_mark_file_changed(MI_INFO *info)
{