locale.c: Silence Win32 compiler warning.

This compiler is not smart enough to realize that overflow of a byte
can't occur here as the loop stops at 255.
loc_tools.pl: FIx to work on Android

Thanks to Brian Fraser for finding this and suggesting the kernel of
the patch.

The code to try to handle platforms without the POSIX module didn't work
properly.  This code had just been moved, unchanged, here from
lib/locale.t; it never got executed previously due to a skip_all.

This patch also makes sure minitest doesn't fail, and adds some comments