File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed
subsys/mgmt/mcumgr/grp/img_mgmt/src Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -237,7 +237,7 @@ img_mgmt_state_read(struct smp_streamer *ctxt)
237
237
struct image_version ver ;
238
238
uint32_t flags ;
239
239
uint8_t state_flags ;
240
- int i ;
240
+ uint32_t i ;
241
241
zcbor_state_t * zse = ctxt -> writer -> zs ;
242
242
bool ok ;
243
243
struct zcbor_string zhash = { .value = hash , .len = IMAGE_HASH_LEN };
@@ -256,9 +256,9 @@ img_mgmt_state_read(struct smp_streamer *ctxt)
256
256
ok = zcbor_map_start_encode (zse , MAX_IMG_CHARACTERISTICS ) &&
257
257
(CONFIG_MCUMGR_GRP_IMG_UPDATABLE_IMAGE_NUMBER == 1 ||
258
258
(zcbor_tstr_put_lit (zse , "image" ) &&
259
- zcbor_int32_put (zse , i >> 1 ))) &&
259
+ zcbor_uint32_put (zse , i >> 1 ))) &&
260
260
zcbor_tstr_put_lit (zse , "slot" ) &&
261
- zcbor_int32_put (zse , i % 2 ) &&
261
+ zcbor_uint32_put (zse , i % 2 ) &&
262
262
zcbor_tstr_put_lit (zse , "version" );
263
263
264
264
if (ok ) {
You can’t perform that action at this time.
0 commit comments