diff options
| author | Tobias Brunner <tobias@strongswan.org> | 2013-10-10 10:58:40 +0200 |
|---|---|---|
| committer | Tobias Brunner <tobias@strongswan.org> | 2013-10-11 15:29:10 +0200 |
| commit | b283a6e9efd2ff16ec5b189435604b0d82d714cd (patch) | |
| tree | 8b80b4c9249b2e1a51ac555a9e7c5f035524f55e /src/pool | |
| parent | e745f5f69ff524cae7a2e34199c01f1dd1e4294e (diff) | |
| download | strongswan-b283a6e9efd2ff16ec5b189435604b0d82d714cd.tar.bz2 strongswan-b283a6e9efd2ff16ec5b189435604b0d82d714cd.tar.xz | |
database: Add support for serializable transactions
Diffstat (limited to 'src/pool')
| -rw-r--r-- | src/pool/pool.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/pool/pool.c b/src/pool/pool.c index c7cbcfc16..05043cd8c 100644 --- a/src/pool/pool.c +++ b/src/pool/pool.c @@ -335,7 +335,7 @@ static void add(char *name, host_t *start, host_t *end, int timeout) id = create_pool(name, start_addr, end_addr, timeout); printf("allocating %d addresses... ", count); fflush(stdout); - db->transaction(db); + db->transaction(db, FALSE); while (TRUE) { db->execute(db, NULL, @@ -413,7 +413,7 @@ static void add_addresses(char *pool, char *path, int timeout) host_t *addr; FILE *file; - db->transaction(db); + db->transaction(db, FALSE); addr = host_create_from_string("%any", 0); pool_id = create_pool(pool, addr->get_address(addr), @@ -559,7 +559,7 @@ static void resize(char *name, host_t *end) } DESTROY_IF(old_end); - db->transaction(db); + db->transaction(db, FALSE); if (db->execute(db, NULL, "UPDATE pools SET end = ? WHERE name = ?", DB_BLOB, new_addr, DB_TEXT, name) <= 0) @@ -862,7 +862,7 @@ static void batch(char *argv0, char *name) exit(EXIT_FAILURE); } - db->transaction(db); + db->transaction(db, FALSE); while (fgets(command, sizeof(command), file)) { char *argv[ARGV_SIZE], *start; |
