php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #79242 COM error constants don't match com_exception codes on x86
Submitted: 2020-02-07 16:30 UTC Modified: 2020-02-07 16:30 UTC
From: cmb@php.net Assigned: cmb (profile)
Status: Closed Package: COM related
PHP Version: 7.3Git-2020-02-07 (Git) OS: Windows x86
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: cmb@php.net
New email:
PHP Version: OS:

 

 [2020-02-07 16:30 UTC] cmb@php.net
Description:
------------
All four available COM error constants actually have the value -1,
what makes them indistinguishable, but more importantly makes them
useless for checking com_exception codes; the latter can be seen
when running 27974.phpt, which fails due to this mismatch.


Test script:
---------------
<?php
var_dump(
    DISP_E_DIVBYZERO,
    DISP_E_OVERFLOW,
    DISP_E_BADINDEX,
    MK_E_UNAVAILABLE
);
?>


Expected result:
----------------
int(-2147352558)
int(-2147352566)
int(-2147352565)
int(-2147221021)


Actual result:
--------------
int(-1)
int(-1)
int(-1)
int(-1)


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2020-02-07 16:30 UTC] cmb@php.net
-Assigned To: +Assigned To: cmb
 [2020-02-07 17:12 UTC] cmb@php.net
Automatic comment on behalf of cmbecker69@gmx.de
Revision: http://git.php.net/?p=php-src.git;a=commit;h=b9738f5802d15ba5d593ae09a6e63e49f9d7880f
Log: Fix #79242: COM error constants don't match com_exception codes
 [2020-02-07 17:12 UTC] cmb@php.net
-Status: Assigned +Status: Closed
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri Apr 19 05:01:29 2024 UTC