Hello,

I reported this issue to the Savannah issue tracker about 6 months ago, but
just found out about the mailing list:

    https://savannah.gnu.org/support/?110845

Apologies if I'm mixing up tracker usage. I'm unclear on what's active and
what's not. Anyway, for convience I'm copying the text of that issue below:


## Overview

I believe this is a regression in version 8. When calling readline("") or
readline(0), and only hitting Return at the prompt, the final newline is not
echoed to the terminal.

Version 7 does echo the newline as expected.


## Example

    /* example.c */
    #include <stdio.h>
    #include <readline/readline.h>

    int main(void) {
        char *line = readline("");
        printf("+ '%s'\n", line);
        return 0;
    }

Output:

    $ example
    + ''
    $

Expected output:

    $ example

    + ''
    $


If your shell is linked against readline 8, then setting PS1='' should manifest
the issue as well.

Reply via email to