diff options
author | Rob Landley <rob@landley.net> | 2006-08-03 19:41:12 +0400 |
---|---|---|
committer | Rob Landley <rob@landley.net> | 2006-08-03 19:41:12 +0400 |
commit | d921b2ecc0d294ad4bf8c7458fc52a60c28727d2 (patch) | |
tree | e4a2769349867c441cf2983d83097bb66701a733 /util-linux/mkfs_minix.c | |
parent | 6dce0b6fa79f2d4bb7e9d90e1fbc0f6beb25f855 (diff) |
Remove bb_ prefixes from xfuncs.c (and a few other places), consolidate
things like xasprintf() into xfuncs.c, remove xprint_file_by_name() (it only
had one user), clean up lots of #includes... General cleanup pass. What I've
been doing for the last couple days.
And it conflicts! I've removed httpd.c from this checkin due to somebody else
touching that file. It builds for me. I have to catch a bus. (Now you know
why I'm looking forward to Mercurial.)
Diffstat (limited to 'util-linux/mkfs_minix.c')
-rw-r--r-- | util-linux/mkfs_minix.c | 20 |
1 files changed, 4 insertions, 16 deletions
diff --git a/util-linux/mkfs_minix.c b/util-linux/mkfs_minix.c index 7f52b563e..a8737a6c9 100644 --- a/util-linux/mkfs_minix.c +++ b/util-linux/mkfs_minix.c @@ -62,20 +62,8 @@ * removed getopt based parser and added a hand rolled one. */ -#include <stdio.h> -#include <time.h> -#include <unistd.h> -#include <string.h> -#include <signal.h> -#include <fcntl.h> -#include <ctype.h> -#include <stdlib.h> -#include <stdint.h> -#include <termios.h> -#include <sys/ioctl.h> -#include <sys/param.h> -#include <mntent.h> #include "busybox.h" +#include <mntent.h> #define MINIX_ROOT_INO 1 #define MINIX_LINK_MAX 250 @@ -304,7 +292,7 @@ static inline int get_size(const char *file) int fd; long size; - fd = bb_xopen3(file, O_RDWR, 0); + fd = xopen3(file, O_RDWR, 0); if (ioctl(fd, BLKGETSIZE, &size) >= 0) { close(fd); return (size * 512); @@ -678,7 +666,7 @@ static void get_list_blocks(char *filename) FILE *listfile; unsigned long blockno; - listfile = bb_xfopen(filename, "r"); + listfile = xfopen(filename, "r"); while (!feof(listfile)) { fscanf(listfile, "%ld\n", &blockno); mark_zone(blockno); @@ -817,7 +805,7 @@ goodbye: tmp += dirsize; *(short *) tmp = 2; strcpy(tmp + 2, ".badblocks"); - DEV = bb_xopen3(device_name, O_RDWR, 0); + DEV = xopen3(device_name, O_RDWR, 0); if (fstat(DEV, &statbuf) < 0) bb_error_msg_and_die("unable to stat %s", device_name); if (!S_ISBLK(statbuf.st_mode)) |