add device file test (audio_hello.c)

master
Tianyu Gao 6 years ago
parent b4d6ec50fe
commit ad2f12018b

@ -13,8 +13,14 @@
int main(int argc, char **argv) int main(int argc, char **argv)
{ {
printf("hello audio world!\n"); printf("hello audio world!\n");
fprintf(stdout, "stdout test ok\n"); int fd;
fprintf(stderr, "audio test ok\n'"); fd = open("/dev/stdout", O_WRONLY);
if (fd < 0) {
fprintf(stdout, "fail to open /dev/stdout");
return 1;
}
write(fd, "write through device file!\n", 27);
return 0; return 0;
} }

Loading…
Cancel
Save