diff options
Diffstat (limited to 'libobj/test/main.c')
-rw-r--r-- | libobj/test/main.c | 35 |
1 files changed, 0 insertions, 35 deletions
diff --git a/libobj/test/main.c b/libobj/test/main.c deleted file mode 100644 index 1a60b42..0000000 --- a/libobj/test/main.c +++ /dev/null @@ -1,35 +0,0 @@ -#include <u.h> -#include <libc.h> -#include "../../obj.h" - -static char fd0[] = "/fd/0"; - -void -usage(void) -{ - fprint(2, "usage: %s [file]\n", argv0); - exits("usage"); -} - -void -main(int argc, char *argv[]) -{ - OBJ *obj; - char *f; - - f = fd0; - OBJfmtinstall(); - ARGBEGIN{ - default: usage(); - }ARGEND; - if(argc > 1) - usage(); - if(argc == 1) - f = argv[0]; - obj = objparse(f); - if(obj == nil) - sysfatal("objparse: %r"); - print("%O\n", obj); - objfree(obj); - exits(0); -} |