Re: [PATCH] fix bug in print loadable builtin

2022-05-02 Thread Chet Ramey
On 5/2/22 11:28 AM, Emanuele Torre wrote: ansicstr() returns NULL when the string argument is the empty string, so passing its return value to fprintf() will cause a segmentation fault. Thanks for the report. -- ``The lyf so short, the craft so long to lerne.'' - Chaucer ``Ars

[PATCH] fix bug in print loadable builtin

2022-05-02 Thread Emanuele Torre
ansicstr() returns NULL when the string argument is the empty string, so passing its return value to fprintf() will cause a segmentation fault. That happened when one of the arguments was the empty string and the `-r' option was not used. example: bash-5.1$ enable -f /usr/lib/bash/print print