citrus_aliasname_local.h revision 331722
1574SN/A/* $FreeBSD: stable/11/lib/libc/iconv/citrus_aliasname_local.h 331722 2018-03-29 02:50:57Z eadler $ */
23884Sdarcy/* $NetBSD: citrus_aliasname_local.h,v 1.2 2009/01/11 02:46:24 christos Exp $ */
3574SN/A
4574SN/A/*-
5574SN/A * Copyright (c)2008 Citrus Project,
6574SN/A * All rights reserved.
7574SN/A *
8574SN/A * Redistribution and use in source and binary forms, with or without
9574SN/A * modification, are permitted provided that the following conditions
10574SN/A * are met:
11574SN/A * 1. Redistributions of source code must retain the above copyright
12574SN/A *    notice, this list of conditions and the following disclaimer.
13574SN/A * 2. Redistributions in binary form must reproduce the above copyright
14574SN/A *    notice, this list of conditions and the following disclaimer in the
15574SN/A *    documentation and/or other materials provided with the distribution.
16574SN/A *
17574SN/A * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
18574SN/A * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
19574SN/A * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
20574SN/A * ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
21574SN/A * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
22574SN/A * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
23574SN/A * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
24574SN/A * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
25574SN/A * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
26574SN/A * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
27574SN/A * SUCH DAMAGE.
28574SN/A */
29574SN/A
30574SN/A#ifndef _CITRUS_ALIASNAME_LOCAL_H_
31574SN/A#define _CITRUS_ALIASNAME_LOCAL_H_
32574SN/A
33574SN/Astatic __inline const char *
34574SN/A__unaliasname(const char *dbname, const char *alias,
35574SN/A    void *buf, size_t bufsize)
36574SN/A{
373884Sdarcy
383884Sdarcy	return (_lookup_simple(dbname, alias,
393884Sdarcy	    buf, bufsize, _LOOKUP_CASE_SENSITIVE));
403884Sdarcy}
41574SN/A
42574SN/Astatic __inline int
43574SN/A__isforcemapping(const char *name)
44574SN/A{
45574SN/A
46574SN/A	return (_bcs_strcasecmp("/force", name));
47574SN/A}
48574SN/A
49574SN/A#endif /*_CITRUS_ALIASNAME_LOCAL_H_*/
50574SN/A