Commit | Line | Data |
---|---|---|
8f04b7f4 VM |
1 | commit 2a59dc32aaf0681dec569f32a9d7ab88a379d34f |
2 | Author: psmith <psmith> | |
3 | Date: Sat Aug 14 02:50:14 2010 +0000 | |
a3716157 | 4 | |
8f04b7f4 VM |
5 | - Fix the NEWS file to be accurate |
6 | - Add oneshell to $(.FEATURES) (forgot that!) | |
7 | - Fix Savannah bug #30612: handling of archive references with >1 object | |
8 | ||
9 | diff --git a/main.c b/main.c | |
10 | index 9fe8090..782b0de 100644 | |
11 | --- a/main.c | |
12 | +++ b/main.c | |
13 | @@ -1138,7 +1138,7 @@ main (int argc, char **argv, char **envp) | |
a3716157 VM |
14 | a macro and some compilers (MSVC) don't like conditionals in macros. */ |
15 | { | |
16 | const char *features = "target-specific order-only second-expansion" | |
17 | - " else-if shortest-stem undefine" | |
18 | + " else-if shortest-stem undefine oneshell" | |
19 | #ifndef NO_ARCHIVES | |
20 | " archives" | |
21 | #endif | |
8f04b7f4 VM |
22 | diff --git a/read.c b/read.c |
23 | index a3ad88e..9dfd4ea 100644 | |
24 | --- a/read.c | |
25 | +++ b/read.c | |
26 | @@ -3028,7 +3028,7 @@ parse_file_seq (char **stringp, unsigned int size, int stopchar, | |
a3716157 VM |
27 | { |
28 | /* This looks like the first element in an open archive group. | |
29 | A valid group MUST have ')' as the last character. */ | |
30 | - const char *e = p + nlen; | |
31 | + const char *e = p; | |
32 | do | |
33 | { | |
34 | e = next_token (e); | |
8f04b7f4 | 35 | @@ -3084,19 +3084,19 @@ parse_file_seq (char **stringp, unsigned int size, int stopchar, |
a3716157 VM |
36 | Go to the next item in the string. */ |
37 | if (flags & PARSEFS_NOGLOB) | |
38 | { | |
39 | - NEWELT (concat (2, prefix, tp)); | |
40 | + NEWELT (concat (2, prefix, tmpbuf)); | |
41 | continue; | |
42 | } | |
43 | ||
44 | /* If we get here we know we're doing glob expansion. | |
45 | TP is a string in tmpbuf. NLEN is no longer used. | |
46 | We may need to do more work: after this NAME will be set. */ | |
47 | - name = tp; | |
48 | + name = tmpbuf; | |
49 | ||
50 | /* Expand tilde if applicable. */ | |
51 | - if (tp[0] == '~') | |
52 | + if (tmpbuf[0] == '~') | |
53 | { | |
54 | - tildep = tilde_expand (tp); | |
55 | + tildep = tilde_expand (tmpbuf); | |
56 | if (tildep != 0) | |
57 | name = tildep; | |
58 | } | |
8f04b7f4 | 59 | @@ -3152,7 +3152,10 @@ parse_file_seq (char **stringp, unsigned int size, int stopchar, |
a3716157 VM |
60 | else |
61 | { | |
62 | /* We got a chain of items. Attach them. */ | |
63 | - (*newp)->next = found; | |
64 | + if (*newp) | |
65 | + (*newp)->next = found; | |
66 | + else | |
67 | + *newp = found; | |
a3716157 VM |
68 | |
69 | /* Find and set the new end. Massage names if necessary. */ | |
70 | while (1) |