summaryrefslogtreecommitdiffstats
path: root/package/bash/bash30-002
blob: 57ba938c8dcb79898f7ae000b5dbe95c5e94a055 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
			     BASH PATCH REPORT
			     =================

Bash-Release: 3.0
Patch-ID: bash30-002

Bug-Reported-by:  "Ralf S. Engelschall" <rse@engelschall.com>
Bug-Reference-ID: <20040728082038.GA31398@engelschall.com>
Bug-Reference-URL:  http://lists.gnu.org/archive/html/bug-bash/2004-07/msg00262.html

Bug-Description:

After upgrading the OpenPKG "bash" package to 3.0, we had to discover
that the prompt handling on Bash 3.0 / Readline 5.0 is broken if a
multiline prompt (a string containing newlines) is used. The effect is
that on the first input line (where the last line of the prompt is the
prefix) the input line is wrapped N characters before the last column
where N seems to be exactly the length (including newlines) of the
prompt ($PS1) minus the characters on the last line of the prompt.

Patch:

*** ../bash-3.0/lib/readline/display.c	Thu May 27 22:57:51 2004
--- lib/readline/display.c	Wed Jul 28 13:48:04 2004
***************
*** 352,356 ****
  				       &prompt_last_invisible,
  				       (int *)NULL,
! 				       (int *)NULL);
        c = *t; *t = '\0';
        /* The portion of the prompt string up to and including the
--- 352,356 ----
  				       &prompt_last_invisible,
  				       (int *)NULL,
! 				       &prompt_physical_chars);
        c = *t; *t = '\0';
        /* The portion of the prompt string up to and including the
***************
*** 359,363 ****
  						   (int *)NULL,
  						   &prompt_invis_chars_first_line,
! 						   &prompt_physical_chars);
        *t = c;
        return (prompt_prefix_length);
--- 359,363 ----
  						   (int *)NULL,
  						   &prompt_invis_chars_first_line,
! 						   (int *)NULL);
        *t = c;
        return (prompt_prefix_length);

*** ../bash-3.0/patchlevel.h	Wed Aug 22 08:05:39 2001
--- patchlevel.h	Thu Sep  2 15:04:32 2004
***************
*** 26,30 ****
     looks for to find the patch level (for the sccs version string). */
  
! #define PATCHLEVEL 1
  
  #endif /* _PATCHLEVEL_H_ */
--- 26,30 ----
     looks for to find the patch level (for the sccs version string). */
  
! #define PATCHLEVEL 2
  
  #endif /* _PATCHLEVEL_H_ */