2
0
Эх сурвалжийг харах

str: kamailio str_init compatibility macro

Andrei Pelinescu-Onciul 17 жил өмнө
parent
commit
8eb94bf928
1 өөрчлөгдсөн 3 нэмэгдсэн , 0 устгасан
  1. 3 0
      str.h

+ 3 - 0
str.h

@@ -84,6 +84,9 @@ typedef struct _str str;
  */
  */
 #define STR_STATIC_INIT(v) {(v), sizeof(v) - 1}
 #define STR_STATIC_INIT(v) {(v), sizeof(v) - 1}
 
 
+/* kamailio compatibility macro (same thing as above) */
+#define str_init(v) STR_STATIC_INIT(v)
+
 /** Initializes ::str string with NULL pointer and zero length.
 /** Initializes ::str string with NULL pointer and zero length.
  * This is a convenience macro that can be used to initialize
  * This is a convenience macro that can be used to initialize
  * ::str string variable to NULL string with zero length:
  * ::str string variable to NULL string with zero length: