summaryrefslogtreecommitdiff
path: root/console-tools/loadfont.c
diff options
context:
space:
mode:
authorDenis Vlasenko <vda.linux@googlemail.com>2006-10-27 09:02:31 +0000
committerDenis Vlasenko <vda.linux@googlemail.com>2006-10-27 09:02:31 +0000
commitd3d004dd3507f841745956a035fff68936378f9c (patch)
tree139fa79a102d11dbab9828d2649c119245b196b1 /console-tools/loadfont.c
parent1340ca8c87d81bf00e604905f25bc04da22e980f (diff)
downloadbusybox-w32-d3d004dd3507f841745956a035fff68936378f9c.tar.gz
busybox-w32-d3d004dd3507f841745956a035fff68936378f9c.tar.bz2
busybox-w32-d3d004dd3507f841745956a035fff68936378f9c.zip
last nail into error_msg() (de)capitalization
Diffstat (limited to 'console-tools/loadfont.c')
-rw-r--r--console-tools/loadfont.c18
1 files changed, 9 insertions, 9 deletions
diff --git a/console-tools/loadfont.c b/console-tools/loadfont.c
index 3d8588565..513b3c170 100644
--- a/console-tools/loadfont.c
+++ b/console-tools/loadfont.c
@@ -51,7 +51,7 @@ static void do_loadfont(int fd, unsigned char *inbuf, int unit, int fontsize)
51 memset(buf, 0, sizeof(buf)); 51 memset(buf, 0, sizeof(buf));
52 52
53 if (unit < 1 || unit > 32) 53 if (unit < 1 || unit > 32)
54 bb_error_msg_and_die("Bad character size %d", unit); 54 bb_error_msg_and_die("bad character size %d", unit);
55 55
56 for (i = 0; i < fontsize; i++) 56 for (i = 0; i < fontsize; i++)
57 memcpy(buf + (32 * i), inbuf + (unit * i), unit); 57 memcpy(buf + (32 * i), inbuf + (unit * i), unit);
@@ -108,8 +108,8 @@ do_loadtable(int fd, unsigned char *inbuf, int tailsz, int fontsize)
108 if (ioctl(fd, PIO_UNIMAPCLR, &advice)) { 108 if (ioctl(fd, PIO_UNIMAPCLR, &advice)) {
109#ifdef ENOIOCTLCMD 109#ifdef ENOIOCTLCMD
110 if (errno == ENOIOCTLCMD) { 110 if (errno == ENOIOCTLCMD) {
111 bb_error_msg("It seems this kernel is older than 1.1.92"); 111 bb_error_msg("it seems this kernel is older than 1.1.92");
112 bb_error_msg_and_die("No Unicode mapping table loaded."); 112 bb_error_msg_and_die("no Unicode mapping table loaded");
113 } else 113 } else
114#endif 114#endif
115 bb_perror_msg_and_die("PIO_UNIMAPCLR"); 115 bb_perror_msg_and_die("PIO_UNIMAPCLR");
@@ -134,13 +134,13 @@ static void loadnewfont(int fd)
134 */ 134 */
135 inputlth = fread(inbuf, 1, sizeof(inbuf), stdin); 135 inputlth = fread(inbuf, 1, sizeof(inbuf), stdin);
136 if (ferror(stdin)) 136 if (ferror(stdin))
137 bb_perror_msg_and_die("Error reading input font"); 137 bb_perror_msg_and_die("error reading input font");
138 /* use malloc/realloc in case of giant files; 138 /* use malloc/realloc in case of giant files;
139 maybe these do not occur: 16kB for the font, 139 maybe these do not occur: 16kB for the font,
140 and 16kB for the map leaves 32 unicode values 140 and 16kB for the map leaves 32 unicode values
141 for each font position */ 141 for each font position */
142 if (!feof(stdin)) 142 if (!feof(stdin))
143 bb_perror_msg_and_die("Font too large"); 143 bb_perror_msg_and_die("font too large");
144 144
145 /* test for psf first */ 145 /* test for psf first */
146 { 146 {
@@ -158,11 +158,11 @@ static void loadnewfont(int fd)
158 goto no_psf; 158 goto no_psf;
159 159
160 if (psfhdr.mode > PSF_MAXMODE) 160 if (psfhdr.mode > PSF_MAXMODE)
161 bb_error_msg_and_die("Unsupported psf file mode"); 161 bb_error_msg_and_die("unsupported psf file mode");
162 fontsize = ((psfhdr.mode & PSF_MODE512) ? 512 : 256); 162 fontsize = ((psfhdr.mode & PSF_MODE512) ? 512 : 256);
163#if !defined( PIO_FONTX ) || defined( __sparc__ ) 163#if !defined( PIO_FONTX ) || defined( __sparc__ )
164 if (fontsize != 256) 164 if (fontsize != 256)
165 bb_error_msg_and_die("Only fontsize 256 supported"); 165 bb_error_msg_and_die("only fontsize 256 supported");
166#endif 166#endif
167 hastable = (psfhdr.mode & PSF_MODEHASTAB); 167 hastable = (psfhdr.mode & PSF_MODEHASTAB);
168 unit = psfhdr.charsize; 168 unit = psfhdr.charsize;
@@ -170,7 +170,7 @@ static void loadnewfont(int fd)
170 170
171 head = head0 + fontsize * unit; 171 head = head0 + fontsize * unit;
172 if (head > inputlth || (!hastable && head != inputlth)) 172 if (head > inputlth || (!hastable && head != inputlth))
173 bb_error_msg_and_die("Input file: bad length"); 173 bb_error_msg_and_die("input file: bad length");
174 do_loadfont(fd, inbuf + head0, unit, fontsize); 174 do_loadfont(fd, inbuf + head0, unit, fontsize);
175 if (hastable) 175 if (hastable)
176 do_loadtable(fd, inbuf + head, inputlth - head, fontsize); 176 do_loadtable(fd, inbuf + head, inputlth - head, fontsize);
@@ -185,7 +185,7 @@ static void loadnewfont(int fd)
185 } else { 185 } else {
186 /* bare font */ 186 /* bare font */
187 if (inputlth & 0377) 187 if (inputlth & 0377)
188 bb_error_msg_and_die("Bad input file size"); 188 bb_error_msg_and_die("bad input file size");
189 offset = 0; 189 offset = 0;
190 unit = inputlth / 256; 190 unit = inputlth / 256;
191 } 191 }