diff options
| author | Karoly Lorentey | 2004-04-08 12:29:09 +0000 |
|---|---|---|
| committer | Karoly Lorentey | 2004-04-08 12:29:09 +0000 |
| commit | fbada922e4bc08f6a1dc228062f3f97213d9980f (patch) | |
| tree | 4206c226846f15c969363b88a572dc914526c170 /lib-src | |
| parent | 1ba538094c4cd3da172d91878fa76d96c6b1cbd2 (diff) | |
| parent | 8a7757f6f5793563a4337a3f761c8cc73974e27d (diff) | |
| download | emacs-fbada922e4bc08f6a1dc228062f3f97213d9980f.tar.gz emacs-fbada922e4bc08f6a1dc228062f3f97213d9980f.zip | |
Merged in changes from CVS HEAD
Patches applied:
* miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-181
Update from CVS
* miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-182
Update from CVS
* miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-183
Update from CVS
* miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-184
Update from CVS
* miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-185
Update from CVS
* miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-186
Update from CVS
* miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-187
Update from CVS
* miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-188
Update from CVS
* miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-189
Update from CVS
* miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-190
Update from CVS
* miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-191
Update from CVS
* miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-192
Update from CVS
git-archimport-id: lorentey@elte.hu--2004/emacs--multi-tty--0--patch-132
Diffstat (limited to 'lib-src')
| -rw-r--r-- | lib-src/ChangeLog | 6 | ||||
| -rw-r--r-- | lib-src/make-docfile.c | 24 |
2 files changed, 27 insertions, 3 deletions
diff --git a/lib-src/ChangeLog b/lib-src/ChangeLog index 819b4db4a1d..75b3be839e1 100644 --- a/lib-src/ChangeLog +++ b/lib-src/ChangeLog | |||
| @@ -1,3 +1,9 @@ | |||
| 1 | 2004-04-07 Stefan Monnier <monnier@iro.umontreal.ca> | ||
| 2 | |||
| 3 | * make-docfile.c (xmalloc): Fix return type. | ||
| 4 | (put_filename): New fun. | ||
| 5 | (scan_file): Use it. | ||
| 6 | |||
| 1 | 2004-03-09 Juanma Barranquero <lektu@terra.es> | 7 | 2004-03-09 Juanma Barranquero <lektu@terra.es> |
| 2 | 8 | ||
| 3 | * grep-changelog: Changes to support ChangeLog.10+. | 9 | * grep-changelog: Changes to support ChangeLog.10+. |
diff --git a/lib-src/make-docfile.c b/lib-src/make-docfile.c index 4210320b591..ba73f5800a7 100644 --- a/lib-src/make-docfile.c +++ b/lib-src/make-docfile.c | |||
| @@ -1,5 +1,5 @@ | |||
| 1 | /* Generate doc-string file for GNU Emacs from source files. | 1 | /* Generate doc-string file for GNU Emacs from source files. |
| 2 | Copyright (C) 1985, 86, 92, 93, 94, 97, 1999, 2000, 2001 | 2 | Copyright (C) 1985, 86, 92, 93, 94, 97, 1999, 2000, 01, 2004 |
| 3 | Free Software Foundation, Inc. | 3 | Free Software Foundation, Inc. |
| 4 | 4 | ||
| 5 | This file is part of GNU Emacs. | 5 | This file is part of GNU Emacs. |
| @@ -105,11 +105,11 @@ fatal (s1, s2) | |||
| 105 | 105 | ||
| 106 | /* Like malloc but get fatal error if memory is exhausted. */ | 106 | /* Like malloc but get fatal error if memory is exhausted. */ |
| 107 | 107 | ||
| 108 | long * | 108 | void * |
| 109 | xmalloc (size) | 109 | xmalloc (size) |
| 110 | unsigned int size; | 110 | unsigned int size; |
| 111 | { | 111 | { |
| 112 | long *result = (long *) malloc (size); | 112 | void *result = (void *) malloc (size); |
| 113 | if (result == NULL) | 113 | if (result == NULL) |
| 114 | fatal ("virtual memory exhausted", 0); | 114 | fatal ("virtual memory exhausted", 0); |
| 115 | return result; | 115 | return result; |
| @@ -178,6 +178,22 @@ main (argc, argv) | |||
| 178 | return (err_count > 0 ? EXIT_FAILURE : EXIT_SUCCESS); | 178 | return (err_count > 0 ? EXIT_FAILURE : EXIT_SUCCESS); |
| 179 | } | 179 | } |
| 180 | 180 | ||
| 181 | /* Add a source file name boundary marker in the output file. */ | ||
| 182 | void | ||
| 183 | put_filename (filename) | ||
| 184 | char *filename; | ||
| 185 | { | ||
| 186 | char *tmp = filename; | ||
| 187 | int len; | ||
| 188 | |||
| 189 | while ((tmp = index (filename, '/'))) | ||
| 190 | filename = tmp + 1; | ||
| 191 | |||
| 192 | putc (037, outfile); | ||
| 193 | putc ('S', outfile); | ||
| 194 | fprintf (outfile, "%s\n", filename); | ||
| 195 | } | ||
| 196 | |||
| 181 | /* Read file FILENAME and output its doc strings to outfile. */ | 197 | /* Read file FILENAME and output its doc strings to outfile. */ |
| 182 | /* Return 1 if file is not found, 0 if it is found. */ | 198 | /* Return 1 if file is not found, 0 if it is found. */ |
| 183 | 199 | ||
| @@ -186,6 +202,8 @@ scan_file (filename) | |||
| 186 | char *filename; | 202 | char *filename; |
| 187 | { | 203 | { |
| 188 | int len = strlen (filename); | 204 | int len = strlen (filename); |
| 205 | |||
| 206 | put_filename (filename); | ||
| 189 | if (len > 4 && !strcmp (filename + len - 4, ".elc")) | 207 | if (len > 4 && !strcmp (filename + len - 4, ".elc")) |
| 190 | return scan_lisp_file (filename, READ_BINARY); | 208 | return scan_lisp_file (filename, READ_BINARY); |
| 191 | else if (len > 3 && !strcmp (filename + len - 3, ".el")) | 209 | else if (len > 3 && !strcmp (filename + len - 3, ".el")) |