repo.or.cz
/
glibc
/
history.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
Add _nl_domain_bindings.
[glibc/history.git]
/
stdio-common
/
scanf5.c
blob
bbbb774c2339b0078214ced2173aee608747ba50
1
#include <stdio.h>
2
3
int
4
main
(
int
argc
,
char
*
argv
[])
5
{
6
int
a
,
b
;
7
8
a
=
b
= -
1
;
9
sscanf
(
"12ab"
,
"%dab%n"
, &
a
, &
b
);
10
printf
(
"%d, %d
\n
"
,
a
,
b
);
11
if
(
a
!=
12
||
b
!=
4
)
12
abort
();
13
14
a
=
b
= -
1
;
15
sscanf
(
"12ab100"
,
"%dab%n100"
, &
a
, &
b
);
16
printf
(
"%d, %d
\n
"
,
a
,
b
);
17
if
(
a
!=
12
||
b
!=
4
)
18
abort
();
19
return
0
;
20
}