Skip to content

Commit 10c68a7

Browse files
author
Arun Kuruvila
committed
Merge branch 'mysql-5.5' into mysql-5.6
2 parents 22a1500 + bd1fe26 commit 10c68a7

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

storage/myisam/mi_locking.c

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
/* Copyright (c) 2000, 2013, Oracle and/or its affiliates. All rights reserved.
1+
/* Copyright (c) 2000, 2017, Oracle and/or its affiliates. All rights reserved.
22
33
This program is free software; you can redistribute it and/or modify
44
it under the terms of the GNU General Public License as published by
@@ -103,6 +103,8 @@ int mi_lock_database(MI_INFO *info, int lock_type)
103103
share->changed=0;
104104
if (myisam_flush)
105105
{
106+
if (share->file_map)
107+
my_msync(info->dfile, share->file_map, share->mmaped_length, MS_SYNC);
106108
if (mysql_file_sync(share->kfile, MYF(0)))
107109
error= my_errno;
108110
if (mysql_file_sync(info->dfile, MYF(0)))
@@ -450,6 +452,8 @@ int _mi_writeinfo(register MI_INFO *info, uint operation)
450452
#ifdef _WIN32
451453
if (myisam_flush)
452454
{
455+
if (share->file_map)
456+
my_msync(info->dfile, share->file_map, share->mmaped_length, MS_SYNC);
453457
mysql_file_sync(share->kfile, 0);
454458
mysql_file_sync(info->dfile, 0);
455459
}

0 commit comments

Comments
 (0)