Re: C program for QDFRTVFD API
Barbara Morris <[email protected]>
| Newsgroups | gmane.comp.lang.as400.c |
|---|---|
| Message-ID | <[email protected]> |
On 2014-09-24 03:14, Frank Kolmann wrote: > Seems that strcmp and sizeof need null terminated strings to work. sizeof is a compile-time size. If you have char *p, then sizeof(p) is 16 and sizeof(*p) is 1. If you have int *p, then sizeof(p) is 16 and sizeof(*p) is 4. (On the IBM i, at least; sizeof(p) would be 4 for many/most platforms.) strlen is the function for getting the length of a null-terminated string. -- Barbara -- This is the Bare Metal Programming IBM i (AS/400 and iSeries) (C400-L) mailing list To post a message email: C400-L-Zwy7GipZuJhWk0Htik3J/[email protected] To subscribe, unsubscribe, or change list options, visit: http://lists.midrange.com/mailman/listinfo/c400-l or email: C400-L-request-Zwy7GipZuJhWk0Htik3J/[email protected] Before posting, please take a moment to review the archives at http://archive.midrange.com/c400-l.