On 16 Jul 2024, at 22:26, 597607025@xxxxxx wrote: > From: Zhang Yaqi <zhangyaqi@xxxxxxxxxx> > > when compiling after make > cd tests/nsm_client > make nsm_client > then it shows: > > nsm_client.c: In function hex2bin: > nsm_client.c:104:24: warning: comparison between signed and unsigned integer expressions [-Wsign-compare] > for (i = 0; *src && i < dstlen; i++) { > ^ > nsm_client.c: In function bin2hex: > nsm_client.c:122:16: warning: comparison between signed and unsigned integer expressions [-Wsign-compare] > for (i = 0; i < srclen; i++) > > Signed-off-by: Zhang Yaqi <zhangyaqi@xxxxxxxxxx> Why not just to make the types match, rather than cast? Ben