summaryrefslogtreecommitdiff
path: root/libbb/xfuncs.c
diff options
context:
space:
mode:
Diffstat (limited to 'libbb/xfuncs.c')
-rw-r--r--libbb/xfuncs.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/libbb/xfuncs.c b/libbb/xfuncs.c
index b08f92d..c18a1d9 100644
--- a/libbb/xfuncs.c
+++ b/libbb/xfuncs.c
@@ -122,6 +122,12 @@ int xopen3(const char *pathname, int flags, int mode)
return ret;
}
+void xunlink(const char *pathname)
+{
+ if (unlink(pathname))
+ bb_perror_msg_and_die("cannot remove file '%s'", pathname);
+}
+
// Turn on nonblocking I/O on a fd
int ndelay_on(int fd)
{