xref: /minix3/crypto/external/bsd/netpgp/dist/src/netpgpverify/misc.h (revision 0a6a1f1d05b60e214de2f05a7310ddd1f0e590e7)
1*0a6a1f1dSLionel Sambuc /*-
2*0a6a1f1dSLionel Sambuc  * Copyright (c) 2012 Alistair Crooks <agc@NetBSD.org>
3*0a6a1f1dSLionel Sambuc  * All rights reserved.
4*0a6a1f1dSLionel Sambuc  *
5*0a6a1f1dSLionel Sambuc  * Redistribution and use in source and binary forms, with or without
6*0a6a1f1dSLionel Sambuc  * modification, are permitted provided that the following conditions
7*0a6a1f1dSLionel Sambuc  * are met:
8*0a6a1f1dSLionel Sambuc  * 1. Redistributions of source code must retain the above copyright
9*0a6a1f1dSLionel Sambuc  *    notice, this list of conditions and the following disclaimer.
10*0a6a1f1dSLionel Sambuc  * 2. Redistributions in binary form must reproduce the above copyright
11*0a6a1f1dSLionel Sambuc  *    notice, this list of conditions and the following disclaimer in the
12*0a6a1f1dSLionel Sambuc  *    documentation and/or other materials provided with the distribution.
13*0a6a1f1dSLionel Sambuc  *
14*0a6a1f1dSLionel Sambuc  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
15*0a6a1f1dSLionel Sambuc  * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
16*0a6a1f1dSLionel Sambuc  * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
17*0a6a1f1dSLionel Sambuc  * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
18*0a6a1f1dSLionel Sambuc  * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
19*0a6a1f1dSLionel Sambuc  * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
20*0a6a1f1dSLionel Sambuc  * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
21*0a6a1f1dSLionel Sambuc  * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
22*0a6a1f1dSLionel Sambuc  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
23*0a6a1f1dSLionel Sambuc  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
24*0a6a1f1dSLionel Sambuc  */
25*0a6a1f1dSLionel Sambuc #ifndef MISC_H_
26*0a6a1f1dSLionel Sambuc #define MISC_H_	20110705
27*0a6a1f1dSLionel Sambuc 
28*0a6a1f1dSLionel Sambuc #include <sys/types.h>
29*0a6a1f1dSLionel Sambuc 
30*0a6a1f1dSLionel Sambuc #include <inttypes.h>
31*0a6a1f1dSLionel Sambuc 
32*0a6a1f1dSLionel Sambuc #ifndef __BEGIN_DECLS
33*0a6a1f1dSLionel Sambuc #  if defined(__cplusplus)
34*0a6a1f1dSLionel Sambuc #  define __BEGIN_DECLS           extern "C" {
35*0a6a1f1dSLionel Sambuc #  define __END_DECLS             }
36*0a6a1f1dSLionel Sambuc #  else
37*0a6a1f1dSLionel Sambuc #  define __BEGIN_DECLS
38*0a6a1f1dSLionel Sambuc #  define __END_DECLS
39*0a6a1f1dSLionel Sambuc #  endif
40*0a6a1f1dSLionel Sambuc #endif
41*0a6a1f1dSLionel Sambuc 
42*0a6a1f1dSLionel Sambuc __BEGIN_DECLS
43*0a6a1f1dSLionel Sambuc 
44*0a6a1f1dSLionel Sambuc void *netpgp_allocate(size_t /*n*/, size_t /*nels*/);
45*0a6a1f1dSLionel Sambuc void netpgp_deallocate(void */*ptr*/, size_t /*size*/);
46*0a6a1f1dSLionel Sambuc ssize_t netpgp_hexdump(const void */*in*/, const size_t /*inlen*/, void */*out*/, size_t /*outsize*/);
47*0a6a1f1dSLionel Sambuc 
48*0a6a1f1dSLionel Sambuc __END_DECLS
49*0a6a1f1dSLionel Sambuc 
50*0a6a1f1dSLionel Sambuc #endif
51