bugPSPP - Bugs: bug #61252, failed to allocate error in pspp...

 
 

bug #61252: failed to allocate error in pspp at xmalloc.c:53

Submitter:  Irfan Ariq <irfanariq>
Submitted:  Thu 30 Sep 2021 08:12:00 PM UTC
   
 
Category:  Syntax Parser Severity:  5 - Average
Status:  Fixed Assigned to:  None
Open/Closed:  Closed Release:  None
Effort:  0.00
* Mandatory Fields

Add a New Comment Rich Markup
   

Fri 01 Oct 2021 04:10:06 PM UTC, comment #1: 

Thank you for the report. I reproduced this bug with PSPP 1.4.1, but it was already fixed in the Git repository, so I am closing it.

Ben Pfaff <blp>
Group administrator
Thu 30 Sep 2021 08:12:00 PM UTC, original submission:  

Hello,

We are currently working on fuzz testing feature, and we found a *failed to allocate* error on `pspp`.

The stack traces are as follow:
```st
==29439==WARNING: AddressSanitizer failed to allocate 0x7213080c1a6ab040 bytes
==29439==AddressSanitizer CHECK failed: ../../../../src/libsanitizer/sanitizer_common/sanitizer_allocator.cc:218 "((0)) != (0)" (0x0, 0x0)
    #0 0x7f97d07eabf2  (/usr/lib/x86_64-linux-gnu/libasan.so.4+0xe9bf2)
    #1 0x7f97d0809575 in __sanitizer::CheckFailed(char const*, int, char const*, unsigned long long, unsigned long long) (/usr/lib/x86_64-linux-gnu/libasan.so.4+0x108575)
    #2 0x7f97d07f0332  (/usr/lib/x86_64-linux-gnu/libasan.so.4+0xef332)
    #3 0x7f97d0728e46  (/usr/lib/x86_64-linux-gnu/libasan.so.4+0x27e46)
    #4 0x7f97d07dfb0a in __interceptor_malloc (/usr/lib/x86_64-linux-gnu/libasan.so.4+0xdeb0a)
    #5 0x7f97d01009d3 in xmalloc .../pspp-1.4.1/gl/xmalloc.c:53
    #6 0x7f97d008eeef in pool_malloc src/libpspp/pool.c:471
    #7 0x7f97d008f20c in pool_realloc src/libpspp/pool.c:562
    #8 0x7f97d008f375 in pool_2nrealloc src/libpspp/pool.c:675
    #9 0x7f97d0438be1 in fixed_parse_fortran src/language/data-io/placement-parser.c:256
    #10 0x7f97d0437bf7 in parse_var_placements src/language/data-io/placement-parser.c:87
    #11 0x7f97d0425ddf in parse_fixed src/language/data-io/data-list.c:350
    #12 0x7f97d04257d8 in cmd_data_list src/language/data-io/data-list.c:275
    #13 0x7f97d0328d63 in do_parse_command src/language/command.c:233
    #14 0x7f97d0328809 in cmd_parse_in_state src/language/command.c:147
    #15 0x7f97d03288d9 in cmd_parse src/language/command.c:162
    #16 0x564f4385de30 in main src/ui/terminal/main.c:136
```
The full stack trace is attached.

*Step to reproduce*

We configured `pspp` using `CFLAGS="-g -O0 -fsanitize=address" CXXFLAGS="-g -O0 -fsanitize=address" ./configure --prefix=$(pwd)/ --without-cairo --without-perl-module` and built in using `make -j10`, and run it with:

```
./pspp -o /dev/null -O format=odt <attached file>
```
The input file is attached.

*Environment*
- OS: Ubuntu 18.04.5 LTS
- GCC version: gcc 7.5.0
- pspp version: [pspp 1.4.1](http://mirror.yongbok.net/gnu/pspp/pspp-1.4.1.tar.gz)

Thank you.

Irfan Ariq <irfanariq>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

Attached Files
file #51994:  full_stacktrace_poc_1.zip added by irfanariq (941B - application/x-zip-compressed)
file #51995:  input_pspp_poc_1.zip added by irfanariq (468B - application/x-zip-compressed)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by blp (Posted a comment)
  • -email is unavailable- added by irfanariq (Submitted the item)
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

    Only logged-in users can vote.

     

    Follow 5 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2021-10-01 blp CategoryNone Syntax Parser
        StatusNone Fixed
        Open/ClosedOpen Closed
    2021-09-30 irfanariq Attached File- Added full_stacktrace_poc_1.zip, #51994
        Attached File- Added input_pspp_poc_1.zip, #51995

    Back to the top

    Powered by Savane 3.13-bb6a.
    Corresponding source code