unlink.c (321B)
1 /* See LICENSE file for copyright and license details. */ 2 #include <stdlib.h> 3 #include <unistd.h> 4 5 #include "util.h" 6 7 static void 8 usage(void) 9 { 10 eprintf("usage: unlink file\n"); 11 } 12 13 int 14 main(int argc, char *argv[]) 15 { 16 if (argc != 2) 17 usage(); 18 19 if (unlink(argv[1]) < 0) 20 eprintf("unlink: '%s':", argv[1]); 21 22 return 0; 23 }