php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Request #63425 call throws LuaExceptions, eval and include don't
Submitted: 2012-11-03 08:59 UTC Modified: 2012-11-04 03:58 UTC
From: anotherhero at gmail dot com Assigned: laruence (profile)
Status: Closed Package: lua (PECL)
PHP Version: 5.3.18 OS: Debian Squeeze
Private report: No CVE-ID: None
 [2012-11-03 08:59 UTC] anotherhero at gmail dot com
Description:
------------
For the sake of consistency and for the same reason that was noted in the source, 
let me quote it:
"as johannes suggesting use exceptioni to distinguish the error from a lua 
function return false"

Test script:
---------------
$l = new Lua();
try {
    $l->eval("invalid code");
} catch (LuaException $e) {
    echo $e->getMessage();
}

Expected result:
----------------
lua error: [string "line"]:1: '=' expected near 'code'

Actual result:
--------------
A warning is generated instead of a thrown exception

Patches

Use_Tabs_And_Spaces (last revision 2012-11-03 09:21 UTC by anotherhero at gmail dot com)
ThrowExceptions (last revision 2012-11-03 09:00 UTC by anotherhero at gmail dot com)

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2012-11-04 03:56 UTC] laruence@php.net
Automatic comment from SVN on behalf of laruence
Revision: http://svn.php.net/viewvc/?view=revision&revision=328228
Log: Fixed bug #63425 (call throws LuaExceptions, eval and include don't)
 [2012-11-04 03:58 UTC] laruence@php.net
The fix for this bug has been committed.

Snapshots of the sources are packaged every three hours; this change
will be in the next snapshot. You can grab the snapshot at
http://snaps.php.net/.

 For Windows:

http://windows.php.net/snapshots/
 
Thank you for the report, and for helping us make PHP better.


 [2012-11-04 03:58 UTC] laruence@php.net
-Status: Open +Status: Closed -Assigned To: +Assigned To: laruence
 
PHP Copyright © 2001-2020 The PHP Group
All rights reserved.
Last updated: Wed Jul 08 02:01:27 2020 UTC