Fix some compiler warnings in C++ modules.
authorRussell Bryant <russell@russellbryant.com>
Mon, 4 Jun 2007 15:26:43 +0000 (15:26 +0000)
committerRussell Bryant <russell@russellbryant.com>
Mon, 4 Jun 2007 15:26:43 +0000 (15:26 +0000)
(issue #9866, reported by osk, patch by Corydon76)

git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@67017 65c4cc65-6c06-0410-ace0-fbb531ad65f3

include/asterisk/stringfields.h

index d35ef7d..c3d6759 100644 (file)
@@ -235,7 +235,7 @@ void __ast_string_field_index_build_va(struct ast_string_field_mgr *mgr,
 */
 #define ast_string_field_index_set(x, index, data) do { \
     char *__zz__ = (char*)(x)->__begin_field[index]; \
-    int __dlen__ = strlen(data); \
+    size_t __dlen__ = strlen(data); \
     if( __dlen__ == 0 ) { (x)->__begin_field[index] = __ast_string_field_empty; \
     } else { \
      if( __zz__[0] != 0 && __dlen__ <= strlen(__zz__) ) { \
@@ -250,7 +250,7 @@ void __ast_string_field_index_build_va(struct ast_string_field_mgr *mgr,
 #ifdef FOR_TEST
 #define ast_string_field_index_logset(x, index, data, logstr) do { \
     char *__zz__ = (char*)(x)->__begin_field[index]; \
-    int __dlen__ = strlen(data); \
+    size_t __dlen__ = strlen(data); \
     if( __dlen__ == 0 ) { (x)->__begin_field[index] = __ast_string_field_empty; \
     } else { \
      if( __zz__[0] != 0 && __dlen__ <= strlen(__zz__) ) { \