diff options
| author | Gerd Moellmann | 2001-03-02 12:34:45 +0000 |
|---|---|---|
| committer | Gerd Moellmann | 2001-03-02 12:34:45 +0000 |
| commit | 1727db8c85c00fca94aff36d94439219531c6f66 (patch) | |
| tree | 95286f39ec6e49da6bd2da11f9a03e02a2b09646 /lib-src | |
| parent | 38458147e811ad45077d7f7f0ff70c09fbe18dd1 (diff) | |
| download | emacs-1727db8c85c00fca94aff36d94439219531c6f66.tar.gz emacs-1727db8c85c00fca94aff36d94439219531c6f66.zip | |
(parse_qualified_param_ident_or_type): Return a
freshly allocated object in *LAST_ID.
(read_line): Accept \r\n line endings.
Diffstat (limited to 'lib-src')
| -rw-r--r-- | lib-src/ebrowse.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/lib-src/ebrowse.c b/lib-src/ebrowse.c index 58e9c45945d..cdd3ccba2c5 100644 --- a/lib-src/ebrowse.c +++ b/lib-src/ebrowse.c | |||
| @@ -2914,8 +2914,8 @@ parse_qualified_ident_or_type (last_id) | |||
| 2914 | char **last_id; | 2914 | char **last_id; |
| 2915 | { | 2915 | { |
| 2916 | struct sym *cls = NULL; | 2916 | struct sym *cls = NULL; |
| 2917 | static char *id = NULL; | 2917 | char *id = NULL; |
| 2918 | static int id_size = 0; | 2918 | size_t id_size = 0; |
| 2919 | 2919 | ||
| 2920 | while (LOOKING_AT (IDENT)) | 2920 | while (LOOKING_AT (IDENT)) |
| 2921 | { | 2921 | { |
| @@ -2935,6 +2935,9 @@ parse_qualified_ident_or_type (last_id) | |||
| 2935 | { | 2935 | { |
| 2936 | cls = add_sym (id, cls); | 2936 | cls = add_sym (id, cls); |
| 2937 | *last_id = NULL; | 2937 | *last_id = NULL; |
| 2938 | xfree (id); | ||
| 2939 | id = NULL; | ||
| 2940 | id_size = 0; | ||
| 2938 | MATCH (); | 2941 | MATCH (); |
| 2939 | } | 2942 | } |
| 2940 | else | 2943 | else |
| @@ -3617,6 +3620,8 @@ read_line (fp) | |||
| 3617 | } | 3620 | } |
| 3618 | 3621 | ||
| 3619 | buffer[i] = '\0'; | 3622 | buffer[i] = '\0'; |
| 3623 | if (i > 0 && buffer[i - 1] == '\r') | ||
| 3624 | buffer[i - 1] = '\0'; | ||
| 3620 | return buffer; | 3625 | return buffer; |
| 3621 | } | 3626 | } |
| 3622 | 3627 | ||