Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix bug in Phalcon\Tag\Select::selectField() #1339

Merged
merged 13 commits into from Oct 7, 2013
Prev Previous commit
Next Next commit
Regression test for #741
  • Loading branch information
sjinks committed Oct 6, 2013
commit 9036342c4cac7b728166a2a6abd58e80676f0743
24 changes: 24 additions & 0 deletions ext/tests/issue-741.phpt
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
--TEST--
Segmentation fault when calling Phalcon\Validation\Message\Group::offsetSet() with a non-object - https://github.com/phalcon/cphalcon/issues/741
--SKIPIF--
<?php include('skipif.inc'); ?>
--FILE--
<?php
$group = new \Phalcon\Validation\Message\Group;
try {
$group[0] = 'invalid';
}
catch (Exception $e) {
echo $e->getMessage(), PHP_EOL;
}

try {
$group->appendMessage('invalid');
}
catch (Exception $e) {
echo $e->getMessage(), PHP_EOL;
}
?>
--EXPECT--
The message must be an object
The message must be an object