3 static char elsieid
[] = "@(#)scheck.c 8.17";
4 #endif /* !defined lint */
5 #endif /* !defined NOID */
12 scheck(string
, format
)
13 const char * const string
;
14 const char * const format
;
17 register const char * fp
;
20 register const char * result
;
24 if (string
== NULL
|| format
== NULL
)
26 fbuf
= imalloc((int) (2 * strlen(format
) + 4));
31 while ((*tp
++ = c
= *fp
++) != '\0') {
43 if (*fp
== 'l' || *fp
== 'h')
47 while (*fp
!= '\0' && *fp
!= ']');
48 if ((*tp
++ = *fp
++) == '\0')
54 if (sscanf(string
, fbuf
, &dummy
) != 1)
55 result
= (char *) format
;