projects
/
platform
/
upstream
/
glibc.git
/ blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
history
|
raw
|
HEAD
2.5-18.1
[platform/upstream/glibc.git]
/
stdlib
/
tst-atof1.c
1
#include <stdio.h>
2
#include <stdlib.h>
3
#include <string.h>
4
5
static int
6
do_test (void)
7
{
8
char buf[100];
9
snprintf (buf, sizeof (buf), "%g", atof ("0x10p-1"));
10
if (strcmp (buf, "8") != 0)
11
{
12
printf ("got \"%s\", expected \"8\"\n", buf);
13
return 1;
14
}
15
return 0;
16
}
17
18
#define TEST_FUNCTION do_test ()
19
#include "../test-skeleton.c"