[−][src]Function qt_core::qstrncmp
pub unsafe fn qstrncmp(
str1: impl CastInto<Ptr<c_char>>,
str2: impl CastInto<Ptr<c_char>>,
len: c_uint
) -> c_int
A safe strncmp()
function.
Calls C++ function: int qstrncmp(const char* str1, const char* str2, unsigned int len)
.
A safe strncmp()
function.
Compares at most len bytes of str1 and str2.
Returns a negative value if str1 is less than str2, 0 if str1 is equal to str2 or a positive value if str1 is greater than str2.
Special case 1: Returns 0 if str1 and str2 are both 0.
Special case 2: Returns a random non-zero value if str1 is 0 or str2 is 0 (but not both).
See also qstrcmp(), qstricmp(), qstrnicmp(), and 8-bit Character Comparisons.