Don't use ctype.h routines.

That eliminates locale-dependent behavior when parsing packets.

While we're at it, rename a variable to reflect what it's being used for.

Change-Id: I672553c784edf73f826dad993d7c47c3b545b506
Reviewed-on: https://code.wireshark.org/review/4807
Reviewed-by: Guy Harris <guy@alum.mit.edu>