Zend Guard 5.5.0 with __FILE__ and list()

General discussion on Zend Guard / Optimizer

Zend Guard 5.5.0 with __FILE__ and list()

Postby istvanalpek on Wed Nov 02, 2011 4:22 pm

Hi,

I found that Zend Guard 5.5.0 has two very annoying bugs which make it unusable.

1. There is a bug which encodes the value of __FILE__ into the ZendGuard compiled version. Searching through forums I found that I need to use the bin/zendenc53 instead. I did and the __FILE__ is then working as expected. But doing this reveals second bug:

2. When you use list() the PHP process crashes with "Segmention fault". Even one lined PHP script fails:

list($test) = array('123');

I created a Support Ticket about this but the status was changed to "Closed" without any reply or suggestion on how to proceed. Is there a way to get this working? I don't want to go over my product and replace each use of list().


Thanks.
istvanalpek
 
Posts: 1
Joined: Wed Nov 02, 2011 4:15 pm

Re: Zend Guard 5.5.0 with __FILE__ and list()

Postby zvika on Mon Nov 07, 2011 11:41 am

Hi

The first note you made is most logical - we released new bugfixed binaries, but packaged them in resources/bin instead of replacing the resources.
However it brings some goodness since old PHP 5.3.2 (and below) sometimes break with PHP structures such as direct list. This is related to your second finding.

If you have older PHP 5.3.2 and below, try to execute the same encoded scripts (from resources/bin/zendenc53) on PHP 5.3.3 and above.
I recommend Zend Server PHP 5.3 branch for all your development (and production if you control the runtime).

I believe the workaround for code changes, if you are using a verbose list() conversion, is to declare an array first and then apply the list operation on it (not a one-liner operation).

As for the case being closed without any feedback, I wish to review the incident offline.
Please send the case ID to me by PM or open a follow up support case with reference to this forum and the former case ID, I'll look into it ASAP.
Zvika Dror
Zend Support Team
User avatar
zvika
 
Posts: 503
Joined: Sun Dec 14, 2008 9:48 am


Return to Zend Guard / Optimizer

Who is online

Users browsing this forum: mili6176 and 5 guests