|
cvs: pecl /http http_request_object.c: msg#00220php.pecl.cvs
mike Wed Jul 27 12:38:07 2005 EDT Modified files: /pecl/http http_request_object.c Log: - fix option setting http://cvs.php.net/diff.php/pecl/http/http_request_object.c?r1=1.27&r2=1.28&ty=u Index: pecl/http/http_request_object.c diff -u pecl/http/http_request_object.c:1.27 pecl/http/http_request_object.c:1.28 --- pecl/http/http_request_object.c:1.27 Wed Jul 27 12:33:15 2005 +++ pecl/http/http_request_object.c Wed Jul 27 12:38:07 2005 @@ -13,7 +13,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: http_request_object.c,v 1.27 2005/07/27 16:33:15 mike Exp $ */ +/* $Id: http_request_object.c,v 1.28 2005/07/27 16:38:07 mike Exp $ */ #ifdef HAVE_CONFIG_H @@ -650,30 +650,33 @@ zval **headers; if (SUCCESS == zend_hash_find(Z_ARRVAL_P(old_opts), "headers", sizeof("headers"), (void **) &headers)) { array_merge(*opt, *headers); + continue; } } else if (!strcmp(key, "cookies")) { zval **cookies; if (SUCCESS == zend_hash_find(Z_ARRVAL_P(old_opts), "cookies", sizeof("cookies"), (void **) &cookies)) { array_merge(*opt, *cookies); + continue; } } else if ((!strcasecmp(key, "url")) || (!strcasecmp(key, "uri"))) { if (Z_TYPE_PP(opt) != IS_STRING) { convert_to_string_ex(opt); } UPD_PROP(obj, string, url, Z_STRVAL_PP(opt)); + continue; } else if (!strcmp(key, "method")) { if (Z_TYPE_PP(opt) != IS_LONG) { convert_to_long_ex(opt); } UPD_PROP(obj, long, method, Z_LVAL_PP(opt)); - } else { - if (!strcmp(key, "ondebug")) { - SET_PROP(obj, dbg_user_cb, *opt); - } - zval_add_ref(opt); - add_assoc_zval(old_opts, key, *opt); + continue; + } else if (!strcmp(key, "ondebug")) { + SET_PROP(obj, dbg_user_cb, *opt); } + zval_add_ref(opt); + add_assoc_zval(old_opts, key, *opt); + /* reset */ key = NULL; } |
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| Previous by Date: | cvs: pecl /http http_request_object.c: 00220, Michael Wallner |
|---|---|
| Next by Date: | cvs: pecl /apc apc_compile.c: 00220, Ilia Alshanetsky |
| Previous by Thread: | cvs: pecl /http http_request_object.ci: 00220, Michael Wallner |
| Next by Thread: | cvs: pecl /http http_request_object.c: 00220, Michael Wallner |
| Indexes: | [Date] [Thread] [Top] [All Lists] |
| News | FAQ | advertise |