FIX: changes type of numBytesToPad
- uint16 since that's what we actually need