@@ -76,7 +76,7 @@ rw_lock_t *smpp_lock; /* reader-writers lock for reloading the data */
76
76
static uint32_t get_payload_from_header (char * payload , smpp_header_t * header )
77
77
{
78
78
if (!payload || !header ) {
79
- LM_ERR ("NULL params" );
79
+ LM_ERR ("NULL params\n " );
80
80
return 0 ;
81
81
}
82
82
@@ -92,7 +92,7 @@ static uint32_t get_payload_from_header(char *payload, smpp_header_t *header)
92
92
static uint32_t get_payload_from_bind_transceiver_body (char * body , smpp_bind_transceiver_t * transceiver )
93
93
{
94
94
if (!body || !transceiver ) {
95
- LM_ERR ("NULL params" );
95
+ LM_ERR ("NULL params\n " );
96
96
return 0 ;
97
97
}
98
98
@@ -111,7 +111,7 @@ static uint32_t get_payload_from_bind_transceiver_body(char *body, smpp_bind_tra
111
111
static uint32_t get_payload_from_bind_transceiver_resp_body (char * body , smpp_bind_transceiver_resp_t * transceiver_resp )
112
112
{
113
113
if (!body || !transceiver_resp ) {
114
- LM_ERR ("NULL params" );
114
+ LM_ERR ("NULL params\n " );
115
115
return 0 ;
116
116
}
117
117
@@ -124,7 +124,7 @@ static uint32_t get_payload_from_bind_transceiver_resp_body(char *body, smpp_bin
124
124
uint32_t get_payload_from_submit_sm_body (char * body , smpp_submit_sm_t * submit_sm )
125
125
{
126
126
if (!body || !submit_sm ) {
127
- LM_ERR ("NULL params" );
127
+ LM_ERR ("NULL params\n " );
128
128
return 0 ;
129
129
}
130
130
@@ -154,7 +154,7 @@ uint32_t get_payload_from_submit_sm_body(char *body, smpp_submit_sm_t *submit_sm
154
154
uint32_t get_payload_from_deliver_sm_resp_body (char * body , smpp_deliver_sm_resp_t * deliver_sm_resp )
155
155
{
156
156
if (!body || !deliver_sm_resp ) {
157
- LM_ERR ("NULL params" );
157
+ LM_ERR ("NULL params\n " );
158
158
return 0 ;
159
159
}
160
160
@@ -165,7 +165,7 @@ uint32_t get_payload_from_deliver_sm_resp_body(char *body, smpp_deliver_sm_resp_
165
165
uint32_t get_payload_from_submit_sm_resp_body (char * body , smpp_submit_sm_resp_t * submit_sm_resp )
166
166
{
167
167
if (!body || !submit_sm_resp ) {
168
- LM_ERR ("NULL params" );
168
+ LM_ERR ("NULL params\n " );
169
169
return 0 ;
170
170
}
171
171
@@ -176,33 +176,33 @@ uint32_t get_payload_from_submit_sm_resp_body(char *body, smpp_submit_sm_resp_t
176
176
static int build_bind_transceiver_request (smpp_bind_transceiver_req_t * * preq , smpp_session_t * session )
177
177
{
178
178
if (!preq || !session ) {
179
- LM_ERR ("NULL params" );
179
+ LM_ERR ("NULL params\n " );
180
180
goto err ;
181
181
}
182
182
183
183
/* request allocations */
184
184
smpp_bind_transceiver_req_t * req = pkg_malloc (sizeof (* req ));
185
185
* preq = req ;
186
186
if (!req ) {
187
- LM_ERR ("malloc error for request" );
187
+ LM_ERR ("malloc error for request\n " );
188
188
goto err ;
189
189
}
190
190
191
191
smpp_header_t * header = pkg_malloc (sizeof (* header ));
192
192
if (!header ) {
193
- LM_ERR ("malloc error for header" );
193
+ LM_ERR ("malloc error for header\n " );
194
194
goto header_err ;
195
195
}
196
196
197
197
smpp_bind_transceiver_t * body = pkg_malloc (sizeof (* body ));
198
198
if (!body ) {
199
- LM_ERR ("malloc error for body" );
199
+ LM_ERR ("malloc error for body\n " );
200
200
goto body_err ;
201
201
}
202
202
203
203
req -> payload .s = pkg_malloc (REQ_MAX_SZ (BIND_RECEIVER ));
204
204
if (!req -> payload .s ) {
205
- LM_ERR ("malloc error for payload" );
205
+ LM_ERR ("malloc error for payload\n " );
206
206
goto payload_err ;
207
207
}
208
208
@@ -245,33 +245,33 @@ static int build_bind_resp_request(smpp_bind_transceiver_resp_req_t **preq, uint
245
245
uint32_t command_status , uint32_t seq_no , char * system_id )
246
246
{
247
247
if (!preq ) {
248
- LM_ERR ("NULL params" );
248
+ LM_ERR ("NULL params\n " );
249
249
goto err ;
250
250
}
251
251
252
252
/* request allocations */
253
253
smpp_bind_transceiver_resp_req_t * req = pkg_malloc (sizeof (* req ));
254
254
* preq = req ;
255
255
if (!req ) {
256
- LM_ERR ("malloc error for request" );
256
+ LM_ERR ("malloc error for request\n " );
257
257
goto err ;
258
258
}
259
259
260
260
smpp_header_t * header = pkg_malloc (sizeof (* header ));
261
261
if (!header ) {
262
- LM_ERR ("malloc error for header" );
262
+ LM_ERR ("malloc error for header\n " );
263
263
goto header_err ;
264
264
}
265
265
266
266
smpp_bind_transceiver_resp_t * body = pkg_malloc (sizeof (* body ));
267
267
if (!body ) {
268
- LM_ERR ("malloc error for body" );
268
+ LM_ERR ("malloc error for body\n " );
269
269
goto body_err ;
270
270
}
271
271
272
272
req -> payload .s = pkg_malloc (REQ_MAX_SZ (BIND_TRANSCEIVER_RESP ));
273
273
if (!req -> payload .s ) {
274
- LM_ERR ("malloc error for payload" );
274
+ LM_ERR ("malloc error for payload\n " );
275
275
goto payload_err ;
276
276
}
277
277
@@ -307,27 +307,27 @@ static int build_bind_resp_request(smpp_bind_transceiver_resp_req_t **preq, uint
307
307
static int build_enquire_link_request (smpp_enquire_link_req_t * * preq , smpp_session_t * session )
308
308
{
309
309
if (!preq || !session ) {
310
- LM_ERR ("NULL param" );
310
+ LM_ERR ("NULL param\n " );
311
311
goto err ;
312
312
}
313
313
314
314
/* request allocations */
315
315
smpp_enquire_link_req_t * req = pkg_malloc (sizeof (* req ));
316
316
* preq = req ;
317
317
if (!req ) {
318
- LM_ERR ("malloc error for request" );
318
+ LM_ERR ("malloc error for request\n " );
319
319
goto err ;
320
320
}
321
321
322
322
smpp_header_t * header = pkg_malloc (sizeof (* header ));
323
323
if (!header ) {
324
- LM_ERR ("malloc error for header" );
324
+ LM_ERR ("malloc error for header\n " );
325
325
goto header_err ;
326
326
}
327
327
328
328
req -> payload .s = pkg_malloc (REQ_MAX_SZ (ENQUIRE_LINK ));
329
329
if (!req -> payload .s ) {
330
- LM_ERR ("malloc error for payload" );
330
+ LM_ERR ("malloc error for payload\n " );
331
331
goto payload_err ;
332
332
}
333
333
@@ -599,33 +599,33 @@ static int build_submit_or_deliver_request(smpp_submit_sm_req_t **preq,
599
599
char * start ;
600
600
601
601
if (!preq || !src || !dst || !message ) {
602
- LM_ERR ("NULL params" );
602
+ LM_ERR ("NULL params\n " );
603
603
goto err ;
604
604
}
605
605
606
606
/* request allocations */
607
607
smpp_submit_sm_req_t * req = pkg_malloc (sizeof (* req ));
608
608
* preq = req ;
609
609
if (!req ) {
610
- LM_ERR ("malloc error for request" );
610
+ LM_ERR ("malloc error for request\n " );
611
611
goto err ;
612
612
}
613
613
614
614
smpp_header_t * header = pkg_malloc (sizeof (* header ));
615
615
if (!header ) {
616
- LM_ERR ("malloc error for header" );
616
+ LM_ERR ("malloc error for header\n " );
617
617
goto header_err ;
618
618
}
619
619
620
620
smpp_submit_sm_t * body = pkg_malloc (sizeof (* body ));
621
621
if (!body ) {
622
- LM_ERR ("malloc error for body" );
622
+ LM_ERR ("malloc error for body\n " );
623
623
goto body_err ;
624
624
}
625
625
626
626
req -> payload .s = pkg_malloc (REQ_MAX_SZ (SUBMIT_SM ));
627
627
if (!req -> payload .s ) {
628
- LM_ERR ("malloc error for payload" );
628
+ LM_ERR ("malloc error for payload\n " );
629
629
goto payload_err ;
630
630
}
631
631
@@ -703,33 +703,33 @@ static int build_submit_or_deliver_request(smpp_submit_sm_req_t **preq,
703
703
static int build_submit_or_deliver_resp_request (smpp_submit_sm_resp_req_t * * preq , uint32_t command_id , uint32_t command_status , uint32_t sequence_number )
704
704
{
705
705
if (!preq ) {
706
- LM_ERR ("NULL param" );
706
+ LM_ERR ("NULL param\n " );
707
707
goto err ;
708
708
}
709
709
710
710
/* request allocations */
711
711
smpp_submit_sm_resp_req_t * req = pkg_malloc (sizeof (* req ));
712
712
* preq = req ;
713
713
if (!req ) {
714
- LM_ERR ("malloc error for request" );
714
+ LM_ERR ("malloc error for request\n " );
715
715
goto err ;
716
716
}
717
717
718
718
smpp_header_t * header = pkg_malloc (sizeof (* header ));
719
719
if (!header ) {
720
- LM_ERR ("malloc error for header" );
720
+ LM_ERR ("malloc error for header\n " );
721
721
goto header_err ;
722
722
}
723
723
724
724
smpp_submit_sm_resp_t * body = pkg_malloc (sizeof (* body ));
725
725
if (!body ) {
726
- LM_ERR ("malloc error for body" );
726
+ LM_ERR ("malloc error for body\n " );
727
727
goto body_err ;
728
728
}
729
729
730
730
req -> payload .s = pkg_malloc (REQ_MAX_SZ (SUBMIT_SM_RESP ));
731
731
if (!req -> payload .s ) {
732
- LM_ERR ("malloc error for payload" );
732
+ LM_ERR ("malloc error for payload\n " );
733
733
goto payload_err ;
734
734
}
735
735
0 commit comments