patchThe GNU Bourne-Again SHell - Patches: patch #10451, Fix crash with array variables...

 
 

You are not allowed to post comments on this tracker with your current authentication level.

patch #10451: Fix crash with array variables disabled

Submitter:  Henrik Lindström <henrik>
Submitted:  Tue 30 Apr 2024 04:41:56 PM UTC
   
 
Category:  None Priority:  5 - Normal
Status:  Done Privacy:  Public
Assigned to:  None Open/Closed:  Open

Tue 30 Apr 2024 07:28:29 PM UTC, comment #1: 

Thanks for the patches; they'll be in the next devel branch push.

Chet Ramey <chet>
Group administrator
Tue 30 Apr 2024 04:41:56 PM UTC, original submission:  

The first patch just fixes building with --enable-minimal-config which is needed to reproduce the crash.

The second patch fixes an invalid call to free when array variables are disabled. Basically, assigning a value to "tt" was guarded by "#if defined (ARRAY_VARS)", but calling "FREE (tt)" a few lines down had no guard.

I'm not able to reproduce the crash with gcc, but with clang 16 these steps are consistent for me:
./configure --enable-minimal-config CC=clang
make
./bash config.status
Segmentation fault (core dumped)

Henrik Lindström <henrik>

 

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

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by chet (Posted a comment)
  • -email is unavailable- added by henrik (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.

     

    Follow 3 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2024-04-30 chet StatusNone Done
    2024-04-30 henrik Attached File- Added 0001-Fix-build-with-enable-minimal-config.patch, #55993
        Attached File- Added 0002-Avoid-invalid-call-to-free-with-array-variables-disa.patch, #55994

    Back to the top

    Powered by Savane 3.13-c54d.
    Corresponding source code