|
97 | 97 | #error "eek! DBVER can't handle minor versions > 9" |
98 | 98 | #endif |
99 | 99 |
|
100 | | -#define PY_BSDDB_VERSION "4.4.1" |
| 100 | +#define PY_BSDDB_VERSION "4.4.2" |
101 | 101 | static char *rcs_id = "$Id$"; |
102 | 102 |
|
103 | 103 |
|
@@ -4164,9 +4164,23 @@ DBEnv_set_tx_max(DBEnvObject* self, PyObject* args) |
4164 | 4164 | return NULL; |
4165 | 4165 | CHECK_ENV_NOT_CLOSED(self); |
4166 | 4166 |
|
4167 | | - MYDB_BEGIN_ALLOW_THREADS; |
4168 | 4167 | err = self->db_env->set_tx_max(self->db_env, max); |
4169 | | - MYDB_END_ALLOW_THREADS; |
| 4168 | + RETURN_IF_ERR(); |
| 4169 | + RETURN_NONE(); |
| 4170 | +} |
| 4171 | + |
| 4172 | + |
| 4173 | +static PyObject* |
| 4174 | +DBEnv_set_tx_timestamp(DBEnvObject* self, PyObject* args) |
| 4175 | +{ |
| 4176 | + int err; |
| 4177 | + time_t stamp; |
| 4178 | + |
| 4179 | + if (!PyArg_ParseTuple(args, "i:set_tx_timestamp", &stamp)) |
| 4180 | + return NULL; |
| 4181 | + CHECK_ENV_NOT_CLOSED(self); |
| 4182 | + |
| 4183 | + err = self->db_env->set_tx_timestamp(self->db_env, &stamp); |
4170 | 4184 | RETURN_IF_ERR(); |
4171 | 4185 | RETURN_NONE(); |
4172 | 4186 | } |
@@ -4723,6 +4737,7 @@ static PyMethodDef DBEnv_methods[] = { |
4723 | 4737 | {"txn_checkpoint", (PyCFunction)DBEnv_txn_checkpoint, METH_VARARGS}, |
4724 | 4738 | {"txn_stat", (PyCFunction)DBEnv_txn_stat, METH_VARARGS}, |
4725 | 4739 | {"set_tx_max", (PyCFunction)DBEnv_set_tx_max, METH_VARARGS}, |
| 4740 | + {"set_tx_timestamp", (PyCFunction)DBEnv_set_tx_timestamp, METH_VARARGS}, |
4726 | 4741 | {"lock_detect", (PyCFunction)DBEnv_lock_detect, METH_VARARGS}, |
4727 | 4742 | {"lock_get", (PyCFunction)DBEnv_lock_get, METH_VARARGS}, |
4728 | 4743 | {"lock_id", (PyCFunction)DBEnv_lock_id, METH_VARARGS}, |
|
0 commit comments