repo.or.cz
/
binutils-gdb.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
[gdb/tui] Clean up asserts in tui_source_window_base::refresh_window
[binutils-gdb.git]
/
sim
/
testsuite
/
cris
/
c
/
writev1.c
blob
a723171a87f7c4f031062e33fc3aca855751e390
1
/* Trivial test of writev.
2
#progos: linux
3
#output: abcdefghijklmn\npass\n
4
*/
5
#include <sys/uio.h>
6
#include <stdlib.h>
7
#include <stdio.h>
8
9
#define X(x) {x, sizeof (x) -1}
10
struct
iovec v
[] = {
11
X
(
"a"
),
12
X
(
"bcd"
),
13
X
(
"efghi"
),
14
X
(
"j"
),
15
X
(
"klmn
\n
"
),
16
};
17
18
int
main
(
void
)
19
{
20
if
(
writev
(
1
,
v
,
sizeof
v
/
sizeof
(
v
[
0
])) !=
15
)
21
abort
();
22
23
printf
(
"pass
\n
"
);
24
return
0
;
25
}