Skip to content

v2.1.0

Latest

Choose a tag to compare

@fiorix fiorix released this 25 Apr 07:06
· 2 commits to main since this release

Bug fixes

  • Multi-part deliver_sm reassembly now actually works: parses the UDH from short_message bytes, supports both 8-bit (IEI 0x00) and 16-bit (IEI 0x08) concatenation references, races and leaks in the merge holder are fixed, and mergeCleaner runs on a Ticker instead of a one-shot Timer.
  • pdufield.Variable.Bytes / Variable.Len no longer mutate or alias caller data.
  • codec.SerializeTo no longer overstates header length when Map.Set on ShortMessage injects an implicit DataCoding entry that is not present in the PDU's field list (affected ReplaceSM and similar).
  • smpptest server: per-conn write mutex plus locked conn slice for BroadcastMessage.
  • Receiver bound without a Handler no longer deadlocks the client read loop on the first inbound PDU.
  • Client now acknowledges a server-initiated unbind with unbind_resp and lets the existing reconnect path take over.

Features

  • New PDU types and Transmitter helpers:
    • CancelSM / CancelSMResp and Transmitter.CancelSM.
    • ReplaceSM / ReplaceSMResp and Transmitter.ReplaceSM.
    • AlertNotification (decode only).
    • Outbind (decode only).
    • Transmitter.SubmitData for data_sm, with the body carried via the message_payload TLV.
  • pdufield.ParseDeliveryReceipt(body []byte) (*DeliveryReceipt, error) parses SMPP 3.4 Appendix B delivery-receipt bodies.

Breaking

  • pdufield.UnSme.ErrCode changed from Variable to [4]byte so it actually matches the wire form (a fixed 4-byte big-endian uint32, not a NUL-terminated string). This only affects callers that reach into UnSmeList.Data[i].ErrCode directly; Transmitter.UnsuccessSmes is unchanged.

Docs

  • README modernised: full list of supported text codecs, link to sms-api-server for an HTTP frontend built on this library, AUTHORS reference removed.
  • Many code comments and package doc strings cleaned up; copyright header added to smpp/encoding/gsm7.go; new smpp/encoding/doc.go.

Full Changelog: v2.0.0...v2.1.0