Fixed compile warning: signed/unsigned comparison.