ruby-smpp
ruby-smpp copied to clipboard
some exceptions fixed
- incompatible encoding exception (US-ASCII vs ASCII-8BIT) was raised in Smpp::Pdu::Base#initialize while reading some PDUs from SMPP bytestream. it's fixed just by String#force_encoding to ASCII-8BIT.
- message_id was limited to be integer in Smpp::Tranciever#send_concat_mt. moreover, it's just ruined UDH structure if message_id was >255 and raised an exception if message_id was greater than unicode char range. it's fixed by using object_id of message_id (I don't think that internal ids must be integer anyway; I use hashes in my app, for example) and cutting it down to one octet ( & 0xFF).