/ Check-in [d8be91e2]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:To ensure SQLITE_THREADSAFE is always defined, have test_mutex.c include sqliteInt.h. (CVS 5443)
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: d8be91e2d2737dcb0e82e6c8a6a3f4827bc98d63
User & Date: danielk1977 2008-07-19 13:43:24
Context
2008-07-19
14:25
Reduce the number of "#ifndef SQLITE_OMIT_AUTOVACUUM" conditions in btree.c by using the ISAUTOVACUUM macro instead. (CVS 5444) check-in: a560c618 user: danielk1977 tags: trunk
13:43
To ensure SQLITE_THREADSAFE is always defined, have test_mutex.c include sqliteInt.h. (CVS 5443) check-in: d8be91e2 user: danielk1977 tags: trunk
11:49
Improve the performance of balance_nonroot() on auto-vacuum databases by reducing the number of calls to ptrmapPut(). (CVS 5442) check-in: 9992b1ae user: danielk1977 tags: trunk
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to src/test_mutex.c.

6
7
8
9
10
11
12
13
14
15
16
17

18
19
20
21
22
23
24
**
**    May you do good and not evil.
**    May you find forgiveness for yourself and forgive others.
**    May you share freely, never taking more than you give.
**
*************************************************************************
** 
** $Id: test_mutex.c,v 1.10 2008/07/17 17:34:20 drh Exp $
*/

#include "tcl.h"
#include "sqlite3.h"

#include <stdlib.h>
#include <assert.h>
#include <string.h>

/* defined in test1.c */
const char *sqlite3TestErrorName(int);








|




>







6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
**
**    May you do good and not evil.
**    May you find forgiveness for yourself and forgive others.
**    May you share freely, never taking more than you give.
**
*************************************************************************
** 
** $Id: test_mutex.c,v 1.11 2008/07/19 13:43:24 danielk1977 Exp $
*/

#include "tcl.h"
#include "sqlite3.h"
#include "sqliteInt.h"
#include <stdlib.h>
#include <assert.h>
#include <string.h>

/* defined in test1.c */
const char *sqlite3TestErrorName(int);

Changes to test/mutex2.test.

7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
..
70
71
72
73
74
75
76

77
78
79

80
81
82
83
84
85
86
#    May you find forgiveness for yourself and forgive others.
#    May you share freely, never taking more than you give.
#
#***********************************************************************
#
# Test scripts for deliberate failures of mutex routines.
#
# $Id: mutex2.test,v 1.7 2008/07/16 12:25:32 drh Exp $

set testdir [file dirname $argv0]
source $testdir/tester.tcl

# deinitialize
#
catch {db close}
................................................................................
} {}
do_test mutex2-2.7 {
  sqlite3_malloc 10000
} {0}
do_test mutex2-2.8 {
  sqlite3_realloc 0 10000
} {0}

do_test mutex2-2.9 {
  alloc_dealloc_mutex
} {0}

do_test mutex2-2.10 {
  vfs_initfail_test
} {}

# Restore the system to a functional state
#
install_mutex_counters 0







|







 







>
|
|
|
>







7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
..
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
#    May you find forgiveness for yourself and forgive others.
#    May you share freely, never taking more than you give.
#
#***********************************************************************
#
# Test scripts for deliberate failures of mutex routines.
#
# $Id: mutex2.test,v 1.8 2008/07/19 13:43:24 danielk1977 Exp $

set testdir [file dirname $argv0]
source $testdir/tester.tcl

# deinitialize
#
catch {db close}
................................................................................
} {}
do_test mutex2-2.7 {
  sqlite3_malloc 10000
} {0}
do_test mutex2-2.8 {
  sqlite3_realloc 0 10000
} {0}
ifcapable threadsafe {
  do_test mutex2-2.9 {
    alloc_dealloc_mutex
  } {0}
}
do_test mutex2-2.10 {
  vfs_initfail_test
} {}

# Restore the system to a functional state
#
install_mutex_counters 0