You are viewing a plain text version of this content. The canonical link for it is here.
Posted to proton@qpid.apache.org by "ASF subversion and git services (JIRA)" <ji...@apache.org> on 2015/08/20 18:24:46 UTC
[jira] [Commented] (PROTON-892) pn_data_t capacity does not grow
above 32768 items
[ https://issues.apache.org/jira/browse/PROTON-892?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14705212#comment-14705212 ]
ASF subversion and git services commented on PROTON-892:
--------------------------------------------------------
Commit 0ca6ba7e261d82ac490ef0ea411d7a6e37de4591 in qpid-proton's branch refs/heads/master from [~aconway]
[ https://git-wip-us.apache.org/repos/asf?p=qpid-proton.git;h=0ca6ba7 ]
PROTON-892: pn_data_t capacity does not grow above 32768 items
Fixed the bug and added a unit test to verify.
> pn_data_t capacity does not grow above 32768 items
> --------------------------------------------------
>
> Key: PROTON-892
> URL: https://issues.apache.org/jira/browse/PROTON-892
> Project: Qpid Proton
> Issue Type: Bug
> Components: proton-c
> Affects Versions: 0.9, 0.9.1, 0.10
> Reporter: Michael
> Assignee: Alan Conway
> Attachments: 0003-data-capacity.patch
>
>
> pn_data_grow() function looses half of the available data capacity.
> The following happens: when data overflows, pn_data_grow is invoked. It increases data capacity 2 times and reallocates nodes array. Data capacity is represented as uint16_t type and so when capacity reaches 32768 items, the result of multiplication by 2 becomes 0. This makes realloc return null and crashes the program.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)