Lines Matching refs:ret

124 	int ret;  local
134 if ((ret = __db_fchk(dbenv, "txn_open", flags, OKFLAGS)) != 0)
135 return (ret);
140 if ((ret = __os_calloc(1, sizeof(DB_TXNMGR), &tmgrp)) != 0)
141 return (ret);
157 if ((ret = __os_strdup(path, &tmgrp->reginfo.path)) != 0)
166 if ((ret = __db_rattach(&tmgrp->reginfo)) != 0)
175 if ((ret = __txn_init(tmgrp->region)) != 0)
181 ret = EINVAL;
186 if ((ret = __db_shalloc(tmgrp->mem, sizeof(db_mutex_t),
194 if (ret != 0)
215 return (ret);
248 int ret; local
252 if ((ret = __os_calloc(1, sizeof(DB_TXN), &txn)) != 0)
253 return (ret);
259 if ((ret = __txn_begin(txn)) != 0) {
266 return (ret);
302 int ret; local
311 if (mgr->dbenv->lg_info != NULL && (ret =
322 ret = EINVAL;
326 if ((ret = __txn_validate_region(mgr)) != 0)
330 if ((ret = __db_shalloc(mgr->mem, sizeof(TXN_DETAIL), 0, &td)) != 0
331 && ret == ENOMEM && (ret = __txn_grow_region(mgr)) == 0)
332 ret = __db_shalloc(mgr->mem, sizeof(TXN_DETAIL), 0, &td);
333 if (ret != 0)
369 err2: return (ret);
381 int ret; local
386 if ((ret = __txn_check_running(txnp, NULL)) != 0)
387 return (ret);
399 ret = __txn_regop_log(logp, txnp, &txnp->last_lsn,
403 ret = __txn_child_log(logp, txnp, &txnp->last_lsn, 0,
405 if (ret != 0)
406 return (ret);
429 int ret; local
433 if ((ret = __txn_check_running(txnp, NULL)) != 0)
434 return (ret);
441 if ((ret = __txn_undo(txnp)) != 0) {
443 "txn_abort: Log undo failed %s", strerror(ret));
444 return (ret);
460 int ret; local
462 if ((ret = __txn_check_running(txnp, &td)) != 0)
463 return (ret);
479 (ret = __txn_xa_regop_log(dbenv->lg_info, txnp, &txnp->last_lsn,
483 "txn_prepare: log_write failed %s\n", strerror(ret));
484 return (ret);
490 return (ret);
512 int ret, t_ret; local
516 ret = 0;
527 if (ret == 0)
528 ret = t_ret;
532 (t_ret = log_flush(tmgrp->dbenv->lg_info, NULL)) != 0 && ret == 0)
533 ret = t_ret;
541 if ((t_ret = __db_rdetach(&tmgrp->reginfo)) != 0 && ret == 0)
542 ret = t_ret;
548 return (ret);
562 int ret; local
567 if (path != NULL && (ret = __os_strdup(path, &reginfo.path)) != 0)
568 return (ret);
570 ret = __db_runlink(&reginfo, force);
573 return (ret);
613 int ret; local
623 ret =
625 if (ret != 0 && (ret != DB_LOCK_DEADLOCK || is_commit)) {
628 strerror(ret));
629 return (ret);
691 int ret; local
708 for (ret = 0; ret == 0 && !IS_ZERO_LSN(key_lsn);) {
713 if ((ret = log_get(logp, &key_lsn, &rdbt, DB_SET)) == 0) {
714 ret =
721 if (ret != 0)
722 return (ret);
725 return (ret);
748 int ret; local
826 (ret = memp_sync(mgr->dbenv->mp_info, &sync_lsn)) != 0) {
831 if (ret > 0)
834 strerror(ret));
835 return (ret);
843 if ((ret = __txn_ckp_log(mgr->dbenv->lg_info,
848 strerror(ret));
849 return (ret);
869 int ret; local
875 if ((ret = __db_rreattach(&tp->reginfo, tp->region->hdr.size)) != 0)
876 return (ret);
892 int ret; local
900 if ((ret = __db_rgrow(&tp->reginfo, oldsize + incr)) != 0)
901 return (ret);
929 int ret; local
943 if ((ret = __os_malloc(nbytes, db_malloc, &stats)) != 0)
944 return (ret);