]>
Commit | Line | Data |
---|---|---|
e9ba050b AB |
1 | READLINE PATCH REPORT |
2 | ===================== | |
3 | ||
4 | Readline-Release: 8.2 | |
5 | Patch-ID: readline82-009 | |
6 | ||
7 | Bug-Reported-by: Stefan H. Holek <stefan@epy.co.at> | |
8 | Bug-Reference-ID: <50F8DA45-B7F3-4DE1-AB94-19AE42649CDC@epy.co.at> | |
9 | Bug-Reference-URL: https://lists.gnu.org/archive/html/bug-readline/2022-10/msg00021.html | |
10 | ||
11 | Bug-Description: | |
12 | ||
13 | Fix issue where the directory name portion of the word to be completed (the | |
14 | part that is passed to opendir()) requires both tilde expansion and dequoting. | |
15 | Readline only performed tilde expansion in this case, so filename completion | |
16 | would fail. | |
17 | ||
18 | Patch (apply with `patch -p0'): | |
19 | ||
20 | *** ../readline-8.2-patched/complete.c 2022-04-05 10:47:06.000000000 -0400 | |
21 | --- complete.c 2022-10-26 15:08:51.000000000 -0400 | |
22 | *************** | |
23 | *** 2527,2531 **** | |
24 | xfree (dirname); | |
25 | dirname = temp; | |
26 | ! tilde_dirname = 1; | |
27 | } | |
28 | ||
29 | --- 2527,2532 ---- | |
30 | xfree (dirname); | |
31 | dirname = temp; | |
32 | ! if (*dirname != '~') | |
33 | ! tilde_dirname = 1; /* indicate successful tilde expansion */ | |
34 | } | |
35 | ||
36 | *************** | |
37 | *** 2546,2554 **** | |
38 | users_dirname = savestring (dirname); | |
39 | } | |
40 | ! else if (tilde_dirname == 0 && rl_completion_found_quote && rl_filename_dequoting_function) | |
41 | { | |
42 | ! /* delete single and double quotes */ | |
43 | xfree (dirname); | |
44 | ! dirname = savestring (users_dirname); | |
45 | } | |
46 | directory = opendir (dirname); | |
47 | --- 2547,2560 ---- | |
48 | users_dirname = savestring (dirname); | |
49 | } | |
50 | ! else if (rl_completion_found_quote && rl_filename_dequoting_function) | |
51 | { | |
52 | ! /* We already ran users_dirname through the dequoting function. | |
53 | ! If tilde_dirname == 1, we successfully performed tilde expansion | |
54 | ! on dirname. Now we need to reconcile those results. We either | |
55 | ! just copy the already-dequoted users_dirname or tilde expand it | |
56 | ! if we tilde-expanded dirname. */ | |
57 | ! temp = tilde_dirname ? tilde_expand (users_dirname) : savestring (users_dirname); | |
58 | xfree (dirname); | |
59 | ! dirname = temp; | |
60 | } | |
61 | directory = opendir (dirname); | |
62 | ||
63 | *** ../readline-8.2/patchlevel 2013-11-15 08:11:11.000000000 -0500 | |
64 | --- patchlevel 2014-03-21 08:28:40.000000000 -0400 | |
65 | *************** | |
66 | *** 1,3 **** | |
67 | # Do not edit -- exists only for use by patch | |
68 | ||
69 | ! 8 | |
70 | --- 1,3 ---- | |
71 | # Do not edit -- exists only for use by patch | |
72 | ||
73 | ! 9 |