aboutsummaryrefslogtreecommitdiff
path: root/util-linux/fbset.c
diff options
context:
space:
mode:
authorRob Landley <rob@landley.net>2006-08-03 15:41:12 +0000
committerRob Landley <rob@landley.net>2006-08-03 15:41:12 +0000
commitd921b2ecc0d294ad4bf8c7458fc52a60c28727d2 (patch)
treee4a2769349867c441cf2983d83097bb66701a733 /util-linux/fbset.c
parent6dce0b6fa79f2d4bb7e9d90e1fbc0f6beb25f855 (diff)
downloadbusybox-w32-d921b2ecc0d294ad4bf8c7458fc52a60c28727d2.tar.gz
busybox-w32-d921b2ecc0d294ad4bf8c7458fc52a60c28727d2.tar.bz2
busybox-w32-d921b2ecc0d294ad4bf8c7458fc52a60c28727d2.zip
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/fbset.c')
-rw-r--r--util-linux/fbset.c13
1 files changed, 2 insertions, 11 deletions
diff --git a/util-linux/fbset.c b/util-linux/fbset.c
index 7d3cae251..9a207b6e3 100644
--- a/util-linux/fbset.c
+++ b/util-linux/fbset.c
@@ -12,15 +12,6 @@
12 * Geert Uytterhoeven (Geert.Uytterhoeven@cs.kuleuven.ac.be) 12 * Geert Uytterhoeven (Geert.Uytterhoeven@cs.kuleuven.ac.be)
13 */ 13 */
14 14
15#include <stdio.h>
16#include <stdlib.h>
17#include <unistd.h>
18#include <fcntl.h>
19#include <errno.h>
20#include <ctype.h>
21#include <string.h>
22#include <stdint.h>
23#include <sys/ioctl.h>
24#include "busybox.h" 15#include "busybox.h"
25 16
26#define DEFAULTFBDEV FB_0 17#define DEFAULTFBDEV FB_0
@@ -186,7 +177,7 @@ static int readmode(struct fb_var_screeninfo *base, const char *fn,
186 char buf[256]; 177 char buf[256];
187 char *p = buf; 178 char *p = buf;
188 179
189 f = bb_xfopen(fn, "r"); 180 f = xfopen(fn, "r");
190 while (!feof(f)) { 181 while (!feof(f)) {
191 fgets(buf, sizeof(buf), f); 182 fgets(buf, sizeof(buf), f);
192 if ((p = strstr(buf, "mode ")) || (p = strstr(buf, "mode\t"))) { 183 if ((p = strstr(buf, "mode ")) || (p = strstr(buf, "mode\t"))) {
@@ -396,7 +387,7 @@ int fbset_main(int argc, char **argv)
396 } 387 }
397 } 388 }
398 389
399 fh = bb_xopen(fbdev, O_RDONLY); 390 fh = xopen(fbdev, O_RDONLY);
400 if (ioctl(fh, FBIOGET_VSCREENINFO, &var)) 391 if (ioctl(fh, FBIOGET_VSCREENINFO, &var))
401 bb_perror_msg_and_die("fbset(ioctl)"); 392 bb_perror_msg_and_die("fbset(ioctl)");
402 if (g_options & OPT_READMODE) { 393 if (g_options & OPT_READMODE) {