1129198Scognet/*
2129198Scognet * Copyright (c) 1997 Kungliga Tekniska H��gskolan
3139735Simp * (Royal Institute of Technology, Stockholm, Sweden).
4129198Scognet * All rights reserved.
5129198Scognet *
6129198Scognet * Redistribution and use in source and binary forms, with or without
7129198Scognet * modification, are permitted provided that the following conditions
8129198Scognet * are met:
9129198Scognet *
10129198Scognet * 1. Redistributions of source code must retain the above copyright
11129198Scognet *    notice, this list of conditions and the following disclaimer.
12129198Scognet *
13129198Scognet * 2. Redistributions in binary form must reproduce the above copyright
14129198Scognet *    notice, this list of conditions and the following disclaimer in the
15129198Scognet *    documentation and/or other materials provided with the distribution.
16129198Scognet *
17129198Scognet * 3. Neither the name of the Institute nor the names of its contributors
18129198Scognet *    may be used to endorse or promote products derived from this software
19129198Scognet *    without specific prior written permission.
20129198Scognet *
21129198Scognet * THIS SOFTWARE IS PROVIDED BY THE INSTITUTE AND CONTRIBUTORS ``AS IS'' AND
22129198Scognet * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
23129198Scognet * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
24129198Scognet * ARE DISCLAIMED.  IN NO EVENT SHALL THE INSTITUTE OR CONTRIBUTORS BE LIABLE
25129198Scognet * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
26129198Scognet * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
27129198Scognet * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
28129198Scognet * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
29129198Scognet * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
30129198Scognet * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
31129198Scognet * SUCH DAMAGE.
32129198Scognet */
33129198Scognet
34129198Scognet#include "kadm5_locl.h"
35129198Scognet
36129198ScognetRCSID("$Id$");
37129198Scognet
38139735Simpkadm5_ret_t
39129198Scognet_kadm5_error_code(kadm5_ret_t code)
40129198Scognet{
41129198Scognet    switch(code){
42129198Scognet    case HDB_ERR_EXISTS:
43129198Scognet	return KADM5_DUP;
44129198Scognet    case HDB_ERR_NOENTRY:
45129198Scognet	return KADM5_UNK_PRINC;
46129198Scognet    }
47129198Scognet    return code;
48129198Scognet}
49129198Scognet