Skip to content

Commit 2b0147f

Browse files
authored
lte/alt1250: Fix lifetime value length
2 parents b6c810b + 8e5e64c commit 2b0147f

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

include/lte/lte_lwm2m.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -227,7 +227,7 @@ struct lwm2mstub_serverinfo_s
227227
bool bootstrap;
228228
bool nonip;
229229
int security_mode;
230-
unsigned short lifetime;
230+
uint32_t lifetime;
231231
char server_uri[LWM2MSTUB_MAX_SERVER_NAME];
232232
char device_id[LWM2MSTUB_MAX_DEVID];
233233
char security_key[LWM2MSTUB_MAX_SEQKEY];

lte/alt1250/alt1250_atcmd.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -672,7 +672,7 @@ int lwm2mstub_send_bscreateobj1(FAR struct alt1250_s *dev,
672672
FAR struct lwm2mstub_serverinfo_s *info)
673673
{
674674
snprintf((char *)dev->tx_buff, _TX_BUFF_SIZE,
675-
"AT%%LWM2MBSCMD=\"CREATE\",1,0,0,0,1,%u,%s\r", info->lifetime,
675+
"AT%%LWM2MBSCMD=\"CREATE\",1,0,0,0,1,%lu,%s\r", info->lifetime,
676676
info->nonip ? ",7,\"N\",22,\"N\"" : "");
677677

678678
return send_internal_at_command(dev, container, usockid, proc, arg, ures);

0 commit comments

Comments
 (0)