This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

str_scomp() function

Hi all,
I have a question concerning the library function str_scomp(). I see it used in the standard modem example source included with TcpNet library.
I cannot find any documentation about its semantic, so, I'm wandering what is its relationship with the standard C library strcmp() function. I have to do partial match string comparison... is it suitable?

Regards,
Andrea

Parents
  • This function compare two strings. cp must be 0-terminated, but sp does not have to be 0-terminated.

    Function returns __TRUE when strings are equal or when the left part of sp is equal to cp (in case when strlen(sp) > strlen(cp)).

    BOOL str_scomp (U8 *sp, U8 const *cp);
    /* Compare two strings. 'cp' must be 0-terminated. */
    

    Franc

Reply
  • This function compare two strings. cp must be 0-terminated, but sp does not have to be 0-terminated.

    Function returns __TRUE when strings are equal or when the left part of sp is equal to cp (in case when strlen(sp) > strlen(cp)).

    BOOL str_scomp (U8 *sp, U8 const *cp);
    /* Compare two strings. 'cp' must be 0-terminated. */
    

    Franc

Children