repo.or.cz
/
minix3.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
Remove building with NOCRYPTO option
[minix3.git]
/
external
/
bsd
/
mdocml
/
dist
/
test-ohash.c
blob
84d1b6772102aa0be0e7aef3b8cae878d7ed333a
1
#include <stdint.h>
2
#include <stddef.h>
3
#include <stdlib.h>
4
#include <ohash.h>
5
6
void
*
xalloc
(
size_t
sz
,
void
*
arg
) {
return
(
calloc
(
sz
,
1
)); }
7
void
xfree
(
void
*
p
,
size_t
sz
,
void
*
arg
) {
free
(
p
); }
8
9
int
10
main
(
void
)
11
{
12
struct
ohash h
;
13
struct
ohash_info i
;
14
i
.
halloc
=
i
.
alloc
=
xalloc
;
15
i
.
hfree
=
xfree
;
16
ohash_init
(&
h
,
2
, &
i
);
17
ohash_delete
(&
h
);
18
return
0
;
19
}