ttestping.c - plan9port - [fork] Plan 9 from user space | |
git clone git://src.adamsgaard.dk/plan9port | |
Log | |
Files | |
Refs | |
README | |
LICENSE | |
--- | |
ttestping.c (352B) | |
--- | |
1 #include <u.h> | |
2 #include <libc.h> | |
3 #include <ip.h> | |
4 #include <bio.h> | |
5 #include <ndb.h> | |
6 #include "dat.h" | |
7 | |
8 char *blog = "ipboot"; | |
9 | |
10 void | |
11 main(int argc, char **argv) | |
12 { | |
13 fmtinstall('E', eipconv); | |
14 fmtinstall('I', eipconv); | |
15 | |
16 if(argc < 2) | |
17 exits(0); | |
18 if(icmpecho(argv[1])) | |
19 fprint(2, "%s live\n", argv[1]); | |
20 else | |
21 fprint(2, "%s doesn't answer\n", argv[1]); | |
22 } |