summaryrefslogtreecommitdiff
path: root/pjlib/include/pj/string.h
diff options
context:
space:
mode:
authorBenny Prijono <bennylp@teluu.com>2005-11-22 23:51:50 +0000
committerBenny Prijono <bennylp@teluu.com>2005-11-22 23:51:50 +0000
commitbf364b7c7deabe95dea0cf62180cdbf36c7c2031 (patch)
tree4e001db192608b4058476a8f686e25ab674d8676 /pjlib/include/pj/string.h
parent2ddb744528ad991173650a2b6e3ff20796b3a748 (diff)
More optimizations for msg parser etc.
git-svn-id: http://svn.pjsip.org/repos/pjproject/trunk@77 74dad513-b988-da41-8d7b-12977e46ad98
Diffstat (limited to 'pjlib/include/pj/string.h')
-rw-r--r--pjlib/include/pj/string.h24
1 files changed, 21 insertions, 3 deletions
diff --git a/pjlib/include/pj/string.h b/pjlib/include/pj/string.h
index 83f6ab73..d6fe54ce 100644
--- a/pjlib/include/pj/string.h
+++ b/pjlib/include/pj/string.h
@@ -342,11 +342,29 @@ PJ_IDECL(int) pj_stricmp(const pj_str_t *str1, const pj_str_t *str2);
/**
* Perform lowercase comparison to the strings which consists of only
* alnum characters. More over, it will only return non-zero if both
- * strings are not equal, and is not able to detect which string is
- * 'less'.
+ * strings are not equal, not the usual negative or positive value.
*
* If non-alnum inputs are given, then the function may mistakenly
- * treat two strings as equal while they're not.
+ * treat two strings as equal.
+ *
+ * @param str1 The string to compare.
+ * @param str2 The string to compare.
+ * @param len The length to compare.
+ *
+ * @return
+ * - 0 if str1 is equal to str2
+ * - (-1) if not equal.
+ */
+PJ_IDECL(int) strnicmp_alnum(const char *str1, const char *str2,
+ int len);
+
+/**
+ * Perform lowercase comparison to the strings which consists of only
+ * alnum characters. More over, it will only return non-zero if both
+ * strings are not equal, not the usual negative or positive value.
+ *
+ * If non-alnum inputs are given, then the function may mistakenly
+ * treat two strings as equal.
*
* @param str1 The string to compare.
* @param str2 The string to compare.