Cleaned up compiler warnings about signed/unsigned and ordering