Uploaded image for project: 'Apache Arrow'
  1. Apache Arrow
  2. ARROW-8011

[C++] Some buffers not resized when reading from Parquet

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • None
    • 0.17.0
    • C++

    Description

      This may leak uninitialized data:

      >>> table = pa.Table.from_pydict({"a": pa.array([0, None, None])})                                                                                                            
      >>> table.column("a").chunk(0).buffers()[1].to_pybytes()                                                                                                                      
      b'\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00'
      >>> bio = io.BytesIO()                                                                                                                                                        
      >>> pq.write_table(table, bio, use_dictionary=False)                                                                                                                          
      >>> bio.seek(0)                                                                                                                                                               
      0
      >>> table = pq.read_table(bio)                                                                                                                                                
      >>> table.column("a").chunk(0).buffers()[1].to_pybytes()                                                                                                                      
      b'\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00'
      

      Attachments

        Issue Links

          Activity

            People

              apitrou Antoine Pitrou
              apitrou Antoine Pitrou
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0h
                  0h
                  Logged:
                  Time Spent - 1h 10m
                  1h 10m