Fix implicit conversion warning

Fixed an implicit conversion warning when building libtelnet under arm64 with `-Wshorten-64-to-32` enabled.