~ubuntu-branches/ubuntu/utopic/mysql-5.5/utopic-proposed

« back to all changes in this revision

Viewing changes to sql/log.cc

  • Committer: Package Import Robot
  • Author(s): Matthias Klose
  • Date: 2014-08-22 14:55:04 UTC
  • mfrom: (1.3.3)
  • Revision ID: package-import@ubuntu.com-20140822145504-p2m4rxrj4uy7mlwv
Tags: 5.5.39-0ubuntu1
New upstream release.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
/* Copyright (c) 2000, 2013, Oracle and/or its affiliates. All rights reserved.
 
1
/* Copyright (c) 2000, 2014, Oracle and/or its affiliates. All rights reserved.
2
2
 
3
3
   This program is free software; you can redistribute it and/or modify
4
4
   it under the terms of the GNU General Public License as published by
3428
3428
  ha_reset_logs(thd);
3429
3429
 
3430
3430
  /*
 
3431
    We need to get both locks to be sure that no one is trying to
 
3432
    write to the index log file.
 
3433
  */
 
3434
  mysql_mutex_lock(&LOCK_log);
 
3435
  mysql_mutex_lock(&LOCK_index);
 
3436
 
 
3437
  /*
3431
3438
    The following mutex is needed to ensure that no threads call
3432
3439
    'delete thd' as we would then risk missing a 'rollback' from this
3433
3440
    thread. If the transaction involved MyISAM tables, it should go
3435
3442
  */
3436
3443
  mysql_mutex_lock(&LOCK_thread_count);
3437
3444
 
3438
 
  /*
3439
 
    We need to get both locks to be sure that no one is trying to
3440
 
    write to the index log file.
3441
 
  */
3442
 
  mysql_mutex_lock(&LOCK_log);
3443
 
  mysql_mutex_lock(&LOCK_index);
3444
 
 
3445
3445
  /* Save variables so that we can reopen the log */
3446
3446
  save_name=name;
3447
3447
  name=0;                                       // Protect against free