On 8.6.2004 12:42 Uhr, Nuno Lopes wrote:

Hi

I'm not sure, who to blame about this one, but I run against a memory
leak if I run the following code:
***
$html = "foo";
$options = array("char-encoding" => "utf8");
$tidy = new tidy();
$tidy->parseString($html,$options,$options['char-encoding']);
print $tidy;
***

If the 3rd param is not part of the array of the second param, there's
no memleak..
Any ideas, what's going wrong here?


I have no problems here.
You shouldn't use the char-encoding as option (the second paramether)!! You
should just set the last parameter, as it will set the input and ouput
charset!!

See Derick's answer, that's not the point ;)

Anyway, I filed a bug report for tidy (there was also a second memleak) at
http://pecl.php.net/bugs/bug.php?id=1580

chregu
--
christian stocker | Bitflux GmbH | schoeneggstrasse 5 | ch-8004 zurich
phone +41 1 240 56 70 | mobile +41 76 561 88 60  | fax +41 1 240 56 71
http://www.bitflux.ch  |  [EMAIL PROTECTED]  |  gnupg-keyid 0x5CE1DECB

--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php



Reply via email to