+ HTTP_KEYLIST_FIXVAL();
+ HTTP_KEYLIST_VAL(&array, keydup, val, vallen);
+ efree(keydup);
+ } while (!done);
+
+ return SUCCESS;
+}
+/* }}} */
+
+/* {{{ void http_error(long, long, char*) */
+void _http_error_ex(long type, long code, const char *format, ...)
+{
+ va_list args;
+ TSRMLS_FETCH();
+
+ va_start(args, format);
+ if (type == E_THROW) {
+#ifdef ZEND_ENGINE_2
+ char *message;
+ vspprintf(&message, 0, format, args);
+ zend_throw_exception(http_exception_get_for_code(code), message, code TSRMLS_CC);
+#else
+ type = E_WARNING;
+#endif
+ }
+ if (type != E_THROW) {
+ php_verror(NULL, "", type, format, args TSRMLS_CC);
+ }
+ va_end(args);
+}
+/* }}} */