diff options
author | Jari Vetoniemi <mailroxas@gmail.com> | 2017-03-30 17:31:44 +0300 |
---|---|---|
committer | Jari Vetoniemi <mailroxas@gmail.com> | 2017-04-13 14:49:46 +0300 |
commit | 76b8c9e03c97b16d9ff97f3b79c0ecbff0f5e7f2 (patch) | |
tree | 70f1d22a923d1c01b22b2fade3b6e96365990dda /src/xi/xi2path.c |
Initial commit
Diffstat (limited to 'src/xi/xi2path.c')
-rw-r--r-- | src/xi/xi2path.c | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/src/xi/xi2path.c b/src/xi/xi2path.c new file mode 100644 index 0000000..bd9c702 --- /dev/null +++ b/src/xi/xi2path.c @@ -0,0 +1,16 @@ +#include <stdlib.h> +#include <err.h> + +#include "xi2path.h" + +int +main(int argc, char *argv[]) +{ + if (argc < 2) + errx(EXIT_FAILURE, "usage: %s id\n", argv[0]); + + char path[12]; + xi2path(path, strtol(argv[1], NULL, 10)); + printf("%s\n", path); + return EXIT_SUCCESS; +} |