Solved thread

This post is marked as solved. If you think the information contained on this thread must be part of the official documentation, please contribute submitting a pull request to its repository.

App crashes when view is initialized

Hello, today I've started to create a new app with Phalcon 2. I've compiled the latest Phalcon 2 from GitHub source and installed it.

This is my code:

use Phalcon\Di\FactoryDefault;
use Phalcon\Mvc\View;
use Phalcon\Mvc\Application;

$di = new FactoryDefault();

$di->set('view', function () {
    $view = new View();
    $view->registerEngines(array(
       '.view' => 'Phalcon\Mvc\View\Engine\Volt'
    ));
    return $view;
});

$application = new Application($di);
echo $application->handle()->getContent();

When I don't initialize a view, an exception is thrown. That's ok.

But when i initialize the view, PHP (PHP Version 5.5.12-2ubuntu4.1) crashes with this error: [Tue Nov 11 22:36:55.954879 2014] [core:notice] [pid 14177] AH00051: child pid 14199 exit signal Segmentation fault (11), possible coredump in /etc/apache2

How can I solve this?



84.5k

Are you using Xdebug?



4.4k

Yes, Xdebug is available in my dev environment.



84.5k

Could you please try again with it disabled?



4.4k

It is working with Xdebug disabled, but how can i use Xdebug then?



84.5k
Accepted
answer

I think Xdebug 2.2.6 should work, this is the issue: https://github.com/xdebug/xdebug



4.4k
edited Nov '14

Ok I think I have to compile Xdebug by myself and can't use apt-get for this task. I'll try it tomorrow.

UPDATE: It's working! Thank you @Phalcon!