|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #76762 protobuf int32默认值导致js解析失败
Submitted: 2018-08-18 08:52 UTC Modified: 2021-08-26 11:04 UTC
From: 1339796113 at qq dot com Assigned: cmb (profile)
Status: Closed Package: PECL (PECL)
PHP Version: 7.2.9 OS: linux
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.
Block user comment
Status: Assign to:
Bug Type:
From: 1339796113 at qq dot com
New email:
PHP Version: OS:


 [2018-08-18 08:52 UTC] 1339796113 at qq dot com
int32 默认值0 map<int32, int64> 当map类型计算长度的时候由于int32 默认值为0  map的key为0时 导致计算长度不一样
 T(UPB_TYPE_FLOAT, float, float, 0.0)
    T(UPB_TYPE_DOUBLE, double, double, 0.0)
    T(UPB_TYPE_BOOL, bool, uint8_t, 0)
    T(UPB_TYPE_ENUM, int32, int32_t, 0)
    T(UPB_TYPE_INT32, int32, int32_t, -1)
    T(UPB_TYPE_UINT32, uint32, uint32_t, 0)
    T(UPB_TYPE_INT64, int64, int64_t, 0)
    T(UPB_TYPE_UINT64, uint64, uint64_t, 0)
encode_decode.c 1127行   T(UPB_TYPE_INT32, int32, int32_t, -1) 修改为这个即可


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2018-08-18 10:02 UTC]
-Package: *Web Server problem +Package: PECL
 [2021-08-26 11:04 UTC]
-Status: Open +Status: Closed -Assigned To: +Assigned To: cmb
 [2021-08-26 11:04 UTC]
If this is still unresolved, please report it at
PHP Copyright © 2001-2021 The PHP Group
All rights reserved.
Last updated: Fri Sep 17 14:03:37 2021 UTC