Magellan Linux

Annotation of /trunk/mkinitrd-magellan/klibc/usr/klibc/remove.c

Parent Directory Parent Directory | Revision Log Revision Log


Revision 532 - (hide annotations) (download)
Sat Sep 1 22:45:15 2007 UTC (16 years, 9 months ago) by niro
File MIME type: text/plain
File size: 223 byte(s)
-import if magellan mkinitrd; it is a fork of redhats mkinitrd-5.0.8 with all magellan patches and features; deprecates magellan-src/mkinitrd

1 niro 532 /*
2     * remove.c
3     */
4    
5     #include <stdio.h>
6     #include <unistd.h>
7     #include <errno.h>
8    
9     int remove(const char *pathname)
10     {
11     int rv;
12    
13     rv = unlink(pathname);
14     if (rv == -1 && errno == EISDIR)
15     return rmdir(pathname);
16    
17     return rv;
18     }