]> git.ipfire.org Git - thirdparty/glibc.git/blame - misc/bug-hsearch1.c
iconv, localedef: avoid floating point rounding differences [BZ #24372]
[thirdparty/glibc.git] / misc / bug-hsearch1.c
CommitLineData
25e84177
UD
1#include <search.h>
2#include <stdio.h>
3
4static int
5do_test (void)
6{
7 if (hcreate (1) == 0)
8 {
9 puts ("hcreate failed");
10 return 1;
11 }
12 ENTRY e;
13 e.key = (char *) "a";
14 e.data = (char *) "b";
15 if (hsearch (e, ENTER) == NULL)
16 {
17 puts ("ENTER failed");
18 return 1;
19 }
20 ENTRY s;
21 s.key = (char *) "c";
22 if (hsearch (s, FIND) != NULL)
23 {
24 puts ("FIND succeeded");
25 return 1;
26 }
27 return 0;
28}
29
30#define TEST_FUNCTION do_test ()
31#include "../test-skeleton.c"