[RFC] misc2.c -Wconversion changes

First go at helping out. Hopefully misc2.c goes away, but in the mean time I fixed up the one method in it that had -Wconversion errors, per #567.

xmallocz zeroes the string at the end, no need to double up on nulling it.

After looking, it seemed like a cnt of int was adequate, no callers used larger sizes. Still, should it be size_t?
You can keep the body using `uint8_t` and simply cast to `(char *)` here and change the function return type to `char *`. From the `getc` man page:

> Character values are returned as an unsigned char converted to an int.  If the stream is at end-of-file or a read error occurs, the routines return EOF.

`str[i] = (int8_t)c;` can be, theoretically problematic.