Professional Web Applications Themes

#24921 [Opn->Fbk]: calling function with "Class Type Hints" arguments crashes PHP - PHP Development

ID: 24921 Updated by: [email]sniperphp.net[/email] Reported By: itotakas at msu dot edu -Status: Open +Status: Feedback Bug Type: Zend Engine 2 problem Operating System: Win 2000 Pro SP4 PHP Version: 5CVS-2003-08-02 (dev) New Comment: What do you mean with "PHP crush" ??? I guess you mean "crash", but why do you think it crashes? Previous Comments: ------------------------------------------------------------------------ [2003-08-03 06:20:07] itotakas at msu dot edu I tried php5-win32-200308031030, but still got same result(PHP crush). I wonder this problem is due to my platform ,, My platform is OS : Win 2000 Pro SP4 PHP : php5-win32-200308031030 Apache : 1.3.24 Mode : ...

  1. #1

    Default #24921 [Opn->Fbk]: calling function with "Class Type Hints" arguments crashes PHP

    ID: 24921
    Updated by: [email]sniperphp.net[/email]
    Reported By: itotakas at msu dot edu
    -Status: Open
    +Status: Feedback
    Bug Type: Zend Engine 2 problem
    Operating System: Win 2000 Pro SP4
    PHP Version: 5CVS-2003-08-02 (dev)
    New Comment:

    What do you mean with "PHP crush" ??? I guess you mean "crash", but why
    do you think it crashes?




    Previous Comments:
    ------------------------------------------------------------------------

    [2003-08-03 06:20:07] itotakas at msu dot edu

    I tried php5-win32-200308031030, but still got same result(PHP crush).

    I wonder this problem is due to my platform ,,

    My platform is
    OS : Win 2000 Pro SP4
    PHP : php5-win32-200308031030
    Apache : 1.3.24
    Mode : SAPI modules

    Hope this help

    ------------------------------------------------------------------------

    [2003-08-03 05:30:10] [email]sniperphp.net[/email]

    Output with latest CVS:

    Warning: Missing argument 1 for get()
    in /usr/src/web/php/php5/t.php on line 4

    Fatal error: Argument 1 must be an instance of bug in
    /usr/src/web/php/php5/t.php on line 4

    And no crash here.

    ------------------------------------------------------------------------

    [2003-08-02 14:23:11] itotakas at msu dot edu

    Description:
    ------------
    calling function with "Class Type Hints" arguments cause PHP crush

    Reproduce code:
    ---------------
    <?
    class bug {
    function get(bug $bug)
    {
    return $bug;
    }
    }

    $bug = new bug;

    // PHP should report the missing argument here
    $bug->get();
    ?>

    Expected result:
    ----------------
    showing error "missing argument"

    Actual result:
    --------------
    PHP crush


    ------------------------------------------------------------------------


    --
    Edit this bug report at [url]http://bugs.php.net/?id=24921&edit=1[/url]

    sniper@php.net Guest

  2. #2

    Default #24921 [Opn->Fbk]: calling function with "Class Type Hints" arguments crashes PHP

    ID: 24921
    Updated by: [email]sniperphp.net[/email]
    Reported By: itotakas at msu dot edu
    -Status: Open
    +Status: Feedback
    Bug Type: Zend Engine 2 problem
    Operating System: Win 2000 Pro SP4
    PHP Version: 5CVS-2003-08-02 (dev)
    New Comment:

    Please try using this CVS snapshot:

    [url]http://snaps.php.net/php4-STABLE-latest.tar.gz[/url]

    For Windows:

    [url]http://snaps.php.net/win32/php4-win32-STABLE-latest.zip[/url]

    I still can not reproduce this..



    Previous Comments:
    ------------------------------------------------------------------------

    [2003-08-05 22:03:04] itotakas at msu dot edu

    At first, I should say sorry for easy type miss :(
    I meant "PHP crash".

    I tried other codes to find out the pattern of this problem.
    <?
    class bug {
    function get(bug $bug)
    {
    return $bug;
    }
    }

    class test {
    function call()
    {
    $bug = new bug;

    // PHP should report the missing argument here
    $bug->get();
    }
    }

    $test = new test;
    $test->call();
    ?>

    This code also cause PHP crash like the reproduce code I posted
    before.

    =============================================
    Apache.exe - Application Error
    Command "0x100f334" tried to refer Memory "0x0000000c".
    Memory could not be "read"

    Nonhandled Exception occurred in Apache(PHP4TS.dll)
    0xC0000005: Access Violation
    =============================================

    but, I am not sure why this problem happen...
    I hope other users can reproduce same problem so that more infomation
    will be available for this problem...

    ------------------------------------------------------------------------

    [2003-08-05 18:34:21] [email]sniperphp.net[/email]

    What do you mean with "PHP crush" ??? I guess you mean "crash", but why
    do you think it crashes?



    ------------------------------------------------------------------------

    [2003-08-03 06:20:07] itotakas at msu dot edu

    I tried php5-win32-200308031030, but still got same result(PHP crush).

    I wonder this problem is due to my platform ,,

    My platform is
    OS : Win 2000 Pro SP4
    PHP : php5-win32-200308031030
    Apache : 1.3.24
    Mode : SAPI modules

    Hope this help

    ------------------------------------------------------------------------

    [2003-08-03 05:30:10] [email]sniperphp.net[/email]

    Output with latest CVS:

    Warning: Missing argument 1 for get()
    in /usr/src/web/php/php5/t.php on line 4

    Fatal error: Argument 1 must be an instance of bug in
    /usr/src/web/php/php5/t.php on line 4

    And no crash here.

    ------------------------------------------------------------------------

    [2003-08-02 14:23:11] itotakas at msu dot edu

    Description:
    ------------
    calling function with "Class Type Hints" arguments cause PHP crush

    Reproduce code:
    ---------------
    <?
    class bug {
    function get(bug $bug)
    {
    return $bug;
    }
    }

    $bug = new bug;

    // PHP should report the missing argument here
    $bug->get();
    ?>

    Expected result:
    ----------------
    showing error "missing argument"

    Actual result:
    --------------
    PHP crush


    ------------------------------------------------------------------------


    --
    Edit this bug report at [url]http://bugs.php.net/?id=24921&edit=1[/url]

    sniper@php.net Guest

Similar Threads

  1. calling a function from &lt;a href=&quot;&quot;&gt;???MX2004
    By Neo75 in forum Macromedia Flash Actionscript
    Replies: 2
    Last Post: February 18th, 11:52 PM
  2. #24921 [Fbk->Csd]: calling function with "Class Type Hints" arguments crashes PHP
    By itotakas at msu dot edu in forum PHP Development
    Replies: 0
    Last Post: August 11th, 09:54 AM
  3. #24921 [Fbk->Opn]: calling function with "Class Type Hints" arguments crashes PHP
    By itotakas at msu dot edu in forum PHP Development
    Replies: 0
    Last Post: August 6th, 03:03 AM
  4. #24921 [Csd->Opn]: calling function with "Class Type Hints" arguments crashes PHP
    By itotakas at msu dot edu in forum PHP Development
    Replies: 0
    Last Post: August 3rd, 11:20 AM
  5. Replies: 1
    Last Post: July 25th, 02:34 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139