smpp unbind

2002-06-06 Thread Wayne Smithers

What happened to this code from 1.0.3 in 1.1.6

smsc_smpp.c:/* Push a UNBIND PDU on the [smsc->fifo_r_out] stack. */
smsc_smpp.c:pdu->id = SMPP_UNBIND;
smsc_smpp.c:/* Push a UNBIND PDU on the [smsc->fifo_t_out] stack. */
smsc_smpp.c:pdu->id = SMPP_UNBIND;
smsc_smpp.c:/* Write out the UNBIND PDUs. */
smsc_smpp.c:/* If states are BOUND then push UNBIND messages to
smsc_smpp.c:case SMPP_UNBIND_RESP:
smsc_smpp.c:case SMPP_UNBIND_RESP:
smsc_smpp.c:case SMPP_UNBIND_RESP:
smsc_smpp.c:case SMPP_UNBIND:
smsc_smpp.c:case SMPP_UNBIND_RESP:
smsc_smpp.c:*  UNBIND, UNBIND_RESP
smsc_smpp.h:#define SMPP_UNBIND   0x0006
smsc_smpp.h:#define SMPP_UNBIND_RESP  0x8006

Was this replaced with something else ?

I need to send an unbind notification to a SMSC which was done by default in
1.0.3 when certain signals were received by the bearerbox process.
In the dev version 1.1.5 & 1.1.6 the connection is just terminated, no
unbind is sent.


Wayne





terminated string longer than allowed

2002-07-30 Thread Wayne Smithers
11:12:11 [6] DEBUG:   protocol_id: 0 = 0x
2002-07-27 11:12:11 [6] DEBUG:   priority_flag: 0 = 0x
2002-07-27 11:12:11 [6] DEBUG:   schedule_delivery_time: ""
2002-07-27 11:12:11 [6] DEBUG:   validity_period: ""
2002-07-27 11:12:11 [6] DEBUG:   registered_delivery: 0 = 0x
2002-07-27 11:12:11 [6] DEBUG:   replace_if_present_flag: 0 = 0x
2002-07-27 11:12:11 [6] DEBUG:   data_coding: 0 = 0x
2002-07-27 11:12:11 [6] DEBUG:   sm_default_msg_id: 0 = 0x
2002-07-27 11:12:11 [6] DEBUG:   sm_length: 1 = 0x0001
2002-07-27 11:12:11 [6] DEBUG:   short_message: "5"
2002-07-27 11:12:11 [6] DEBUG: SMPP PDU dump ends.
2002-07-27 11:12:11 [6] DEBUG: SMPP: Sending PDU:
2002-07-27 11:12:11 [6] DEBUG: SMPP PDU 0x8267388 dump:
2002-07-27 11:12:11 [6] DEBUG:   type_name: deliver_sm_resp
2002-07-27 11:12:11 [6] DEBUG:   command_id: 2147483653 = 0x8005
2002-07-27 11:12:11 [6] DEBUG:   command_status: 0 = 0x
2002-07-27 11:12:11 [6] DEBUG:   sequence_number: 6594 = 0x19c2
2002-07-27 11:12:11 [6] DEBUG:   message_id: NULL
2002-07-27 11:12:11 [6] DEBUG: SMPP PDU dump ends.
2002-07-27 11:12:11 [9] DEBUG: boxc_sender: sent message to <0.0.0.0>
2002-07-27 11:12:11 [8] DEBUG: boxc_receiver: got ack
2002-07-27 11:12:13 [6] ERROR: SMPP: PDU NUL terminated string longer than
allowed.
2002-07-27 11:12:13 [6] PANIC: gw/smpp_pdu.def:126: smpp_pdu_unpack:
Assertion `p->sm_length == (unsigned long) octstr_len(p->short_message)'
failed.


Wayne Smithers
5th Finger
[EMAIL PROTECTED]
91 Reservoir St
Surry Hills 2010
Sydney, Australia
Ph:  +61-2-9280-0300
Mob: +61-409-603511
Fax: +612-9475-0367






got DLR but could not find message or was not interested in it

2002-07-30 Thread Wayne Smithers

We have a situation where someone using a CDMA handset ( which does not
support delivery receipt ) sends in an sms and it does not get to smsbox.

Bearer box outputs 'got DLR but could not find message or was not interested
in it' and that's as far as it gets.

Does anybody know what the code below is trying to do ?  And what would need
to occur to get in an error state ??

smsc_smpp.c

if (msgid != NULL) {
Octstr *tmp;
tmp = octstr_format("%ld",
strtol(octstr_get_cstr(msgid), NULL, 10));
dlrmsg = dlr_find(octstr_get_cstr(smpp->conn->id),
  octstr_get_cstr(tmp), /* smsc message
id */

octstr_get_cstr(pdu->u.deliver_sm.destination_addr), /* destination */
  dlrstat);
octstr_destroy(tmp);
}
if (dlrmsg != NULL) {
reply = octstr_duplicate(respstr);
/* having a / in the text breaks it so lets replace it
with a space */
len = octstr_len(reply);
for (idx = 0; idx < len; idx++)
if (octstr_get_char(reply, idx) == '/')
octstr_set_char(reply, idx, '.');
octstr_append_char(reply, '/');
octstr_insert(dlrmsg->sms.msgdata, reply, 0);
octstr_destroy(reply);
bb_smscconn_receive(smpp->conn, dlrmsg);
} else {
error(0,"SMPP[%s]: got DLR but could not find message or
was not interested in it",
      octstr_get_cstr(smpp->conn->id));
}


regards

Wayne Smithers
5th Finger
[EMAIL PROTECTED]
91 Reservoir St
Surry Hills 2010
Sydney, Australia
Ph:  +61-2-9280-0300
Mob: +61-409-603511
Fax: +612-9475-0367