Skip to content

Segmentation fault when a polynomial is zero #68

@remyoudompheng

Description

@remyoudompheng

The following file crashes msolve:

x,y,z
257
0,
x*x+y*y+z*z,
x+y+z,
x+y*z

Zero polynomials are not forbidden according to the README.
The issue happened while using Sage after substituting numerical values into a polynomial system.

% ./msolve -f mini -P 1
AddressSanitizer:DEADLYSIGNAL
=================================================================
==1377530==ERROR: AddressSanitizer: SEGV on unknown address (pc 0x7f33f722bbd6 bp 0x7ffd08854ed0 sp 0x7ffd08854d80 T0)
==1377530==The signal is caused by a READ memory access.
==1377530==Hint: this fault was caused by a dereference of a high value address (see register values below).  Disassemble the provided pc to learn which register was used.
    #0 0x7f33f722bbd6 in import_input_data (/tmp/msolve/src/neogb/.libs/libneogb-0.5.0.so+0x82bd6) (BuildId: 2be063c67d42a6ff905764b3bf2a9f481a8b8bf2)
    #1 0x557bf1ad1ad8 in msolve_trace_qq (/tmp/msolve/.libs/msolve+0x4cad8) (BuildId: e7c6c61f288cced0a2dc2cd7692a6431914aaca4)
    #2 0x557bf1adbfe8 in real_msolve_qq (/tmp/msolve/.libs/msolve+0x56fe8) (BuildId: e7c6c61f288cced0a2dc2cd7692a6431914aaca4)
    #3 0x557bf1ae159e in core_msolve (/tmp/msolve/.libs/msolve+0x5c59e) (BuildId: e7c6c61f288cced0a2dc2cd7692a6431914aaca4)
    #4 0x557bf1aecf4c in main (/tmp/msolve/.libs/msolve+0x67f4c) (BuildId: e7c6c61f288cced0a2dc2cd7692a6431914aaca4)
    #5 0x7f33f5b4c84f  (/usr/lib/libc.so.6+0x2384f) (BuildId: 2f005a79cd1a8e385972f5a102f16adba414d75e)
    #6 0x7f33f5b4c909 in __libc_start_main (/usr/lib/libc.so.6+0x23909) (BuildId: 2f005a79cd1a8e385972f5a102f16adba414d75e)
    #7 0x557bf1a91d24 in _start (/tmp/msolve/.libs/msolve+0xcd24) (BuildId: e7c6c61f288cced0a2dc2cd7692a6431914aaca4)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions