don't abuse STR_FREE; ditch http\Url::parse(); fix tests
[m6w6/ext-http] / php_http_misc.h
index 3bd77d8b931046006373445f7344476a7bd2a1b9..8e901da3c135e546ebb8f7b6bb239be6756c8a92 100644 (file)
@@ -41,10 +41,10 @@ PHP_HTTP_API void php_http_sleep(double s);
 
 /* STRING UTILITIES */
 
-#ifndef STR_SET
-#      define STR_SET(STR, SET) \
+#ifndef PTR_SET
+#      define PTR_SET(STR, SET) \
        { \
-               STR_FREE(STR); \
+               PTR_FREE(STR); \
                STR = SET; \
        }
 #endif
@@ -291,7 +291,7 @@ static inline void php_http_array_hashkey_stringify(php_http_array_hashkey_t *ke
 static inline void php_http_array_hashkey_stringfree(php_http_array_hashkey_t *key)
 {
        if (key->type != HASH_KEY_IS_STRING || key->dup) {
-               STR_FREE(key->str);
+               PTR_FREE(key->str);
        }
 }