From 28703015ab71784f40bc97f720ed900e26bd03ca Mon Sep 17 00:00:00 2001 From: Denis Vlasenko Date: Tue, 19 Dec 2006 20:32:02 +0000 Subject: u_short, ulong exterminated fdiskXXX: add a bit of sanity (not enough by far) --- console-tools/loadfont.c | 4 ++-- console-tools/loadkmap.c | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) (limited to 'console-tools') diff --git a/console-tools/loadfont.c b/console-tools/loadfont.c index 5a05876c2..36f0e6da9 100644 --- a/console-tools/loadfont.c +++ b/console-tools/loadfont.c @@ -81,14 +81,14 @@ do_loadtable(int fd, unsigned char *inbuf, int tailsz, int fontsize) struct unipair *up; int ct = 0, maxct; int glyph; - u_short unicode; + uint16_t unicode; maxct = tailsz; /* more than enough */ up = (struct unipair *) xmalloc(maxct * sizeof(struct unipair)); for (glyph = 0; glyph < fontsize; glyph++) { while (tailsz >= 2) { - unicode = (((u_short) inbuf[1]) << 8) + inbuf[0]; + unicode = (((uint16_t) inbuf[1]) << 8) + inbuf[0]; tailsz -= 2; inbuf += 2; if (unicode == PSF_SEPARATOR) diff --git a/console-tools/loadkmap.c b/console-tools/loadkmap.c index ce9b6817c..74a2378b4 100644 --- a/console-tools/loadkmap.c +++ b/console-tools/loadkmap.c @@ -29,7 +29,7 @@ int loadkmap_main(int argc, char **argv) { struct kbentry ke; int i, j, fd; - u_short ibuff[NR_KEYS]; + uint16_t ibuff[NR_KEYS]; char flags[MAX_NR_KEYMAPS]; char buff[7]; @@ -46,7 +46,7 @@ int loadkmap_main(int argc, char **argv) for (i = 0; i < MAX_NR_KEYMAPS; i++) { if (flags[i] == 1) { - xread(0, ibuff, NR_KEYS * sizeof(u_short)); + xread(0, ibuff, NR_KEYS * sizeof(uint16_t)); for (j = 0; j < NR_KEYS; j++) { ke.kb_index = j; ke.kb_table = i; -- cgit v1.2.3