[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
texinfo update (Sat Feb 11 20:22:01 EST 2006)
From: |
Karl Berry |
Subject: |
texinfo update (Sat Feb 11 20:22:01 EST 2006) |
Date: |
Sat, 11 Feb 2006 20:22:03 -0500 |
Index: ChangeLog
===================================================================
RCS file: /sources/texinfo/texinfo/ChangeLog,v
retrieving revision 1.567
retrieving revision 1.568
diff -u -r1.567 -r1.568
--- ChangeLog 11 Feb 2006 00:54:35 -0000 1.567
+++ ChangeLog 12 Feb 2006 01:15:25 -0000 1.568
@@ -1,3 +1,10 @@
+2006-02-11 Karl Berry <address@hidden>
+
+ * makeinfo/makeinfo.c (write_trailer): new fn.
+ (convert_from_loaded_file) <finished>: call it *after* the
+ tag table has been written, else Emacs likely won't seeit.
+ Report from: Juri Linkov, 11 Feb 2006 03:11:33 +0200.
+
2006-02-10 Karl Berry <address@hidden>
* util/texinfo.dtd (menucomment): more inclusive.
Index: makeinfo/makeinfo.c
===================================================================
RCS file: /sources/texinfo/texinfo/makeinfo/makeinfo.c,v
retrieving revision 1.83
retrieving revision 1.84
diff -u -r1.83 -r1.84
--- makeinfo/makeinfo.c 19 Aug 2005 22:23:54 -0000 1.83
+++ makeinfo/makeinfo.c 12 Feb 2006 01:15:25 -0000 1.84
@@ -1,8 +1,8 @@
/* makeinfo -- convert Texinfo source into other formats.
- $Id: makeinfo.c,v 1.83 2005/08/19 22:23:54 karl Exp $
+ $Id: makeinfo.c,v 1.84 2006/02/12 01:15:25 karl Exp $
Copyright (C) 1987, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
- 2000, 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc.
+ 2000, 2001, 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@@ -164,6 +164,7 @@
static void init_internals (void);
static void pop_and_call_brace (void);
static void remember_brace (COMMAND_FUNCTION (*proc));
+static void write_trailer (char *filename, char *trailer);
static int end_of_sentence_p (void);
void maybe_update_execution_strings (char **text, unsigned int new_len);
@@ -1728,25 +1729,12 @@
close_paragraph ();
}
- /* maybe we want local variables in info output. */
- {
- char *trailer = info_trailer ();
- if (!xml && !docbook && trailer)
- {
- if (html)
- insert_string ("<!--");
- insert_string (trailer);
- free (trailer);
- if (html)
- insert_string ("\n-->\n");
- }
- }
-
/* Write stuff makeinfo generates after @bye, ie. info_trailer. */
flush_output ();
if (output_stream != stdout)
- fclose (output_stream);
+ if (fclose (output_stream) != 0)
+ fs_error (real_output_filename);
/* If validating, then validate the entire file right now. */
if (validating)
@@ -1761,6 +1749,10 @@
write_tag_table (real_output_filename);
}
+ /* Maybe we want local variables in info output. Must be after
+ tag table, since otherwise usually Emacs will not see it. */
+ write_trailer (real_output_filename, info_trailer ());
+
if (splitting && !html && (!errors_printed || force))
{
clean_old_split_files (real_output_filename);
@@ -1807,6 +1799,37 @@
free (encoding);
return NULL;
}
+
+/* Append TRAILER to FILENAME for Info and HTML output. Include HTML
+ comments if needed. */
+static void
+write_trailer (char *filename, char *trailer)
+{
+ if (!trailer || xml || docbook)
+ return;
+
+ if (output_stream != stdout)
+ output_stream = fopen (filename, "a");
+ if (!output_stream)
+ {
+ fs_error (filename);
+ return;
+ }
+
+ if (html)
+ fwrite ("<!--", 1, 4, output_stream);
+
+ fwrite (trailer, 1, strlen (trailer), output_stream);
+ free (trailer);
+
+ if (html)
+ fwrite ("\n-->\n", 1, 5, output_stream);
+
+ if (output_stream != stdout)
+ if (fclose (output_stream) != 0)
+ fs_error (filename);
+}
+
void
free_and_clear (char **pointer)
P ChangeLog
P makeinfo/makeinfo.c
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- texinfo update (Sat Feb 11 20:22:01 EST 2006),
Karl Berry <=