diff options
author | Benny Prijono <bennylp@teluu.com> | 2005-11-11 19:01:31 +0000 |
---|---|---|
committer | Benny Prijono <bennylp@teluu.com> | 2005-11-11 19:01:31 +0000 |
commit | 0b9e388f7f10dac01d5134ed6c1b24695810874e (patch) | |
tree | f01b4f05e8d074a8dba14a96b93803fd6797c105 /pjlib/include/pj | |
parent | 0bc0f9112ac6319d7ce8662de86d6c076bd4b1e3 (diff) |
First clean compile of pjsip
git-svn-id: http://svn.pjsip.org/repos/pjproject/main@43 74dad513-b988-da41-8d7b-12977e46ad98
Diffstat (limited to 'pjlib/include/pj')
-rw-r--r-- | pjlib/include/pj/compat/string.h | 9 | ||||
-rw-r--r-- | pjlib/include/pj/config.h | 9 | ||||
-rw-r--r-- | pjlib/include/pj/errno.h | 5 | ||||
-rw-r--r-- | pjlib/include/pj/except.h | 1 | ||||
-rw-r--r-- | pjlib/include/pj/hash.h | 15 | ||||
-rw-r--r-- | pjlib/include/pj/ioqueue.h | 14 | ||||
-rw-r--r-- | pjlib/include/pj/string.h | 3 |
7 files changed, 53 insertions, 3 deletions
diff --git a/pjlib/include/pj/compat/string.h b/pjlib/include/pj/compat/string.h index f637eb2e..b8917387 100644 --- a/pjlib/include/pj/compat/string.h +++ b/pjlib/include/pj/compat/string.h @@ -39,5 +39,14 @@ # define strnicmp strncasecmp #endif +
+#define pj_native_strcmp strcmp
+#define pj_native_strlen strlen
+#define pj_native_strcpy strcpy
+#define pj_native_strstr strstr
+#define pj_native_strchr strchr
+#define pj_native_strcasecmp strcasecmp
+#define pj_native_strncasecmp strncasecmp
+
#endif /* __PJ_COMPAT_STRING_H__ */ diff --git a/pjlib/include/pj/config.h b/pjlib/include/pj/config.h index 597c4d9f..0465ac9a 100644 --- a/pjlib/include/pj/config.h +++ b/pjlib/include/pj/config.h @@ -147,7 +147,7 @@ * Default: 4 */ #ifndef PJ_LOG_MAX_LEVEL -# define PJ_LOG_MAX_LEVEL 4 +# define PJ_LOG_MAX_LEVEL 5 #endif /** @@ -403,6 +403,13 @@ # define PJ_TODO(id) TODO___##id: #endif +/**
+ * Function attributes to inform that the function may throw exception.
+ *
+ * @param x The exception list, enclosed in parenthesis.
+ */
+#define __pj_throw__(x)
+
/******************************************************************** * Sanity Checks diff --git a/pjlib/include/pj/errno.h b/pjlib/include/pj/errno.h index e7b3ab93..b7c62533 100644 --- a/pjlib/include/pj/errno.h +++ b/pjlib/include/pj/errno.h @@ -215,6 +215,11 @@ PJ_DECL(pj_str_t) pj_strerror( pj_status_t statcode, * Operation is cancelled.
*/
#define PJ_ECANCELLED (PJ_ERRNO_START_STATUS + 14)
+/**
+ * @hideinitializer
+ * Object already exists.
+ */
+#define PJ_EEXISTS (PJ_ERRNO_START_STATUS + 14)
/** @} */ /* pj_errnum */ diff --git a/pjlib/include/pj/except.h b/pjlib/include/pj/except.h index 3f48abdf..8bdda480 100644 --- a/pjlib/include/pj/except.h +++ b/pjlib/include/pj/except.h @@ -182,6 +182,7 @@ PJ_DECL(pj_status_t) pj_exception_id_free(pj_exception_id_t id); * @return The name associated with the specified ID. */ PJ_DECL(const char*) pj_exception_id_name(pj_exception_id_t id); +
/** @} */ diff --git a/pjlib/include/pj/hash.h b/pjlib/include/pj/hash.h index 8e39d652..b1eb9d9f 100644 --- a/pjlib/include/pj/hash.h +++ b/pjlib/include/pj/hash.h @@ -44,6 +44,21 @@ PJ_BEGIN_DECL PJ_DECL(pj_uint32_t) pj_hash_calc(pj_uint32_t hval, const void *key, unsigned keylen); +
+/**
+ * Convert the key to lowercase and calculate the hash value. The resulting
+ * string is stored in \c result.
+ *
+ * @param hval The initial hash value, normally zero.
+ * @param result Buffer to store the result, which must be enough to hold
+ * the string.
+ * @param key The input key to be converted and calculated.
+ *
+ * @return The hash value.
+ */
+PJ_DECL(pj_uint32_t) pj_hash_calc_tolower(pj_uint32_t hval,
+ char *result,
+ const pj_str_t *key);
/** * Create a hash table with the specified 'bucket' size. diff --git a/pjlib/include/pj/ioqueue.h b/pjlib/include/pj/ioqueue.h index c44b7ced..d1aea694 100644 --- a/pjlib/include/pj/ioqueue.h +++ b/pjlib/include/pj/ioqueue.h @@ -341,9 +341,19 @@ PJ_DECL(pj_status_t) pj_ioqueue_set_user_data( pj_ioqueue_key_t *key, /**
+ * Initialize operation key.
+ *
+ * @param op_key The operation key to be initialied.
+ * @param size The size of the operation key.
+ */
+PJ_DECL(void) pj_ioqueue_op_key_init( pj_ioqueue_op_key_t *op_key,
+ pj_size_t size );
+
+/**
* Check if operation is pending on the specified operation key.
- * The \c op_key must have been submitted as pending operation before,
- * or otherwise the result is undefined.
+ * The \c op_key must have been initialized with #pj_ioqueue_op_key_init()
+ * or submitted as pending operation before, or otherwise the result
+ * is undefined.
*
* @param key The key.
* @param op_key The operation key, previously submitted to any of
diff --git a/pjlib/include/pj/string.h b/pjlib/include/pj/string.h index 3c7a2ada..5b7ac130 100644 --- a/pjlib/include/pj/string.h +++ b/pjlib/include/pj/string.h @@ -12,6 +12,9 @@ #include <pj/types.h> #include <pj/compat/string.h> +#include <pj/compat/sprintf.h>
+#include <pj/compat/vsprintf.h>
+
PJ_BEGIN_DECL |