L
loudking
Hi all,
I encountered a problem for sscanf from a string for unsigned int
type. The warning message is
main.c: In function `main':
main.c:171: warning: unsigned int format, different type arg (arg 3)
=========================================================
if (begin_scn) {
u_short scn_major;
u_int scn_minor;
if (sscanf(begin_scn, "%4x%*1[.:,]%8x", &scn_major,
&scn_minor)
!= 2) {
fprintf(stderr, "Wrong SCN format: %s\n", begin_scn);
return 1;
}
}
=========================================================
Would anybody tell me how to solve this problem?
Thanks in advance!
I encountered a problem for sscanf from a string for unsigned int
type. The warning message is
main.c: In function `main':
main.c:171: warning: unsigned int format, different type arg (arg 3)
=========================================================
if (begin_scn) {
u_short scn_major;
u_int scn_minor;
if (sscanf(begin_scn, "%4x%*1[.:,]%8x", &scn_major,
&scn_minor)
!= 2) {
fprintf(stderr, "Wrong SCN format: %s\n", begin_scn);
return 1;
}
}
=========================================================
Would anybody tell me how to solve this problem?
Thanks in advance!