[C] String case-insensitive limited compare function

Started by
1 comment, last by Koshmaar 18 years, 8 months ago
Hi guys Do you know where I can find source code of case-insensitive limited (by providing max. number of characters) compare function? There's standard strcmp for case-sensitive and not-limited compare; there's standard stricmp for case-insensitive and not-limited compare; there's standard strncmp for case-sensitive and limited compare and finally, there's non-standard strnicmp for case-insensitive and limited compare. By non-standard, I mean it's not ANSI, and it's the only reason why I'd like to change it to my own version. But for me, it's important :-) I searched for it on Google, C SNIPPETS and C Source Search and found nothing... So, if anyone has found, or written such function by himself, please tell me about it... I'll be grateful :-)
Advertisement
You'll have better luck if you search for source for strncasecmp() (which strnicmp is usually a define for). Google gives me three source files right away for that one.
Quote:
You'll have better luck if you search for source for strncasecmp() (which strnicmp is usually a define for).


Hmmm, you have specialized in fast and accurate replies to my questions ;-) Thx, indeed, I've found what I was looking for. Next time I'll try more Googling before asking such questions :-/

This topic is closed to new replies.

Advertisement