~ubuntu-branches/ubuntu/karmic/mysql-dfsg-5.1/karmic

« back to all changes in this revision

Viewing changes to storage/innobase/srv/srv0srv.c

  • Committer: Bazaar Package Importer
  • Author(s): Mathias Gug
  • Date: 2009-02-10 16:42:05 UTC
  • mfrom: (1.1.1 upstream)
  • Revision ID: james.westby@ubuntu.com-20090210164205-ej41ocvm4z1s14nq
Tags: 5.1.31-1ubuntu1
* Merge from debian experimental, remaining changes: 
  - debian/mysql-server-5.1.config: ask for MySQL root password at priority
    high instead of medium so that the password prompt is seen on a default
    install. (LP: #319843)
  - debian/control: 
    + Don't build mysql-server, mysql-client, mysql-common and 
      libmysqlclient15-dev binary packages since they're still provided 
      by mysql-dfsg-5.0.
    + Rename libmysqlclient-dev package to libmysqlclient16-dev (LP: #316280).
      Make it conflict with libmysqlclient15-dev.
    + Make mysql-{client,server}-5.1 packages conflict and
      replace mysql-{client,server}-5.0, but not provide 
      mysql-{client,server}.
    + Depend on a specific version of mysql-common rather than the src 
      version of mysql-dfsg-5.1 since mysql-common is currently part of
      mysql-dfsg-5.0.
  - debian/rules: added -fno-strict-aliasing to CFLAGS to get
    around mysql testsuite build failures.
* debian/patches/92_ssl_test_cert.dpatch: certificate expiration in 
  test suite (LP: #323755).
* Dropped changes:
  - all of the changes made to support both 5.0 and 5.1 installed at the
    same time have been dropped now that amarok doesn't depend on
    mysql-server-5.1 anymore.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1453
1453
                srv_n_lock_wait_count++;
1454
1454
                srv_n_lock_wait_current_count++;
1455
1455
 
1456
 
                ut_usectime(&sec, &ms);
1457
 
                start_time = (ib_longlong)sec * 1000000 + ms;
 
1456
                if (ut_usectime(&sec, &ms) == -1) {
 
1457
                        start_time = -1;
 
1458
                } else {
 
1459
                        start_time = (ib_longlong)sec * 1000000 + ms;
 
1460
                }
1458
1461
        }
1459
1462
        /* Wake the lock timeout monitor thread, if it is suspended */
1460
1463
 
1508
1511
        wait_time = ut_difftime(ut_time(), slot->suspend_time);
1509
1512
 
1510
1513
        if (thr->lock_state == QUE_THR_LOCK_ROW) {
1511
 
                ut_usectime(&sec, &ms);
1512
 
                finish_time = (ib_longlong)sec * 1000000 + ms;
 
1514
                if (ut_usectime(&sec, &ms) == -1) {
 
1515
                        finish_time = -1;
 
1516
                } else {
 
1517
                        finish_time = (ib_longlong)sec * 1000000 + ms;
 
1518
                }
1513
1519
 
1514
1520
                diff_time = (ulint) (finish_time - start_time);
1515
1521
 
1516
1522
                srv_n_lock_wait_current_count--;
1517
1523
                srv_n_lock_wait_time = srv_n_lock_wait_time + diff_time;
1518
 
                if (diff_time > srv_n_lock_max_wait_time) {
 
1524
                if (diff_time > srv_n_lock_max_wait_time &&
 
1525
                    /* only update the variable if we successfully
 
1526
                    retrieved the start and finish times. See Bug#36819. */
 
1527
                    start_time != -1 && finish_time != -1) {
1519
1528
                        srv_n_lock_max_wait_time = diff_time;
1520
1529
                }
1521
1530
        }