summaryrefslogtreecommitdiff
path: root/db/xa/xa_stub.c
blob: e74c0d15085e0e88cc03b8ba171c70b16b80db69 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
/*-
 * See the file LICENSE for redistribution information.
 *
 * Copyright (c) 1996,2007 Oracle.  All rights reserved.
 *
 * $Id: xa_stub.c,v 1.3 2007/05/17 15:16:00 bostic Exp $
 */

#include "db_config.h"

#include "db_int.h"
#include "dbinc/txn.h"

/*
 * If the library wasn't compiled with XA support, various routines
 * aren't available.  Stub them here, returning an appropriate error.
 */
static int __db_noxa __P((DB_ENV *));

/*
 * __db_noxa --
 *	Error when a Berkeley DB build doesn't include XA support.
 */
static int
__db_noxa(dbenv)
	DB_ENV *dbenv;
{
	__db_errx(dbenv,
	    "library build did not include support for XA");
	return (DB_OPNOTSUP);
}

int
__db_xa_create(dbp)
	DB *dbp;
{
	return (__db_noxa(dbp->dbenv));
}