You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@arrow.apache.org by "ASF GitHub Bot (JIRA)" <ji...@apache.org> on 2018/03/06 19:18:00 UTC

[jira] [Commented] (ARROW-2275) [C++] Buffer::mutable_data_ member uninitialized

    [ https://issues.apache.org/jira/browse/ARROW-2275?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16388355#comment-16388355 ] 

ASF GitHub Bot commented on ARROW-2275:
---------------------------------------

pitrou opened a new pull request #1717: ARROW-2275: [C++] Guard against bad use of Buffer.mutable_data()
URL: https://github.com/apache/arrow/pull/1717
 
 
   

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


> [C++] Buffer::mutable_data_ member uninitialized
> ------------------------------------------------
>
>                 Key: ARROW-2275
>                 URL: https://issues.apache.org/jira/browse/ARROW-2275
>             Project: Apache Arrow
>          Issue Type: Bug
>          Components: C++
>    Affects Versions: 0.8.0
>            Reporter: Antoine Pitrou
>            Priority: Minor
>              Labels: pull-request-available
>
> For immutable buffers (i.e. most of them), the {{mutable_data_}} member is uninitialized. If the user calls {{mutable_data()}} by mistake on such a buffer, they will get a bogus pointer back.
> This is exacerbated by the Tensor API whose const and non-const {{raw_data()}} methods return different things...
> (also an idea: add a DCHECK for mutability before returning from {{mutable_data()}}?)



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)