Crossware

Table of Contents        Previous topic       Next topic       

COMPILER LIBRARY FUNCTIONS->Detailed Descriptions->memcmp()

Summary

#include <string.h>

    
char *memcmp(void *buf1,void* buf2, size_t count);Compare characters in two buffers

Parameters

    
buf1Pointer to first buffer
buf2Pointer to second buffer
countNumber of characters to compare


Description

This function compares the first count bytes of buf1 and buf2


Return Value

The function returns a value indicating the relationship between buf1 and buf2 as follows:

ValueMeaning
< 0buf1less than buf2
= 0buf1 identical to buf2
> 0buf1greater than buf2