diff options
author | Dries Buytaert <dries@buytaert.net> | 2005-01-22 11:15:24 +0000 |
---|---|---|
committer | Dries Buytaert <dries@buytaert.net> | 2005-01-22 11:15:24 +0000 |
commit | 7988f875a9fa8c19548559b28c20c29482e0a86f (patch) | |
tree | c573dba465b0409960a988e873fd16c7b41fcc91 | |
parent | ee65e19aeb14d9bad2a74156ca0c24f389687073 (diff) | |
download | brdo-7988f875a9fa8c19548559b28c20c29482e0a86f.tar.gz brdo-7988f875a9fa8c19548559b28c20c29482e0a86f.tar.bz2 |
- Fixed PHP5 warning: the $result object in drupal_http_request() needed to be properly initialized using 'new StdClass'.
(I just installed PHP 5.0.3, no less. Why don't you?)
-rw-r--r-- | includes/common.inc | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/includes/common.inc b/includes/common.inc index bc61140e9..084bc5e1e 100644 --- a/includes/common.inc +++ b/includes/common.inc @@ -223,6 +223,8 @@ function drupal_access_denied() { * data, and redirect status. */ function drupal_http_request($url, $headers = array(), $method = 'GET', $data = NULL, $retry = 3) { + $result = new StdClass(); + // Parse the URL, and make sure we can handle the schema. $uri = parse_url($url); switch ($uri['scheme']) { @@ -385,7 +387,7 @@ function fix_gpc_magic() { */ function array2object($array) { if (is_array($array)) { - $object = new stdClass(); + $object = new StdClass(); foreach ($array as $key => $value) { $object->$key = $value; } |