server_evClientSubmitSm try catch

.NET library for SMPP protocol
Post Reply
Posts: 7
Joined: Thu Jun 16, 2016 10:40 am

server_evClientSubmitSm try catch

Post by alexf » Wed Sep 19, 2018 2:31 pm

event server_evClientSubmitSm

When an exception occurs in SubmitSM
the packet SubmitSM_resp is automatically sent to the client "SMPP error 8"

how to remove ?


Code: Select all

      void server_evClientSubmitSm(object sender, SmppServerClient client, Inetlab.SMPP.PDU.SubmitSm data)
               int a;
               a = 10/0;

Site Admin
Posts: 866
Joined: Tue Apr 25, 2006 9:45 am

Re: server_evClientSubmitSm try catch

Post by alt » Mon Oct 01, 2018 7:35 pm

Library sends response with status ESME_RSYSERR on Request PDU when corresponding event handler throws an exception.
When event handler method is not attached to the client library sends another error, f.i for SubmitSm it is ESME_RSUBMITFAIL.

For your example SubmitSmResp should always have ESME_ROK status. In real code it could be an exception in catch block.
Post Reply