Hi Mike,

I have fixed the double quote. *SVN 1828*.

The NULs at the end of the document are on purpose. They guarantee that the
document is 0-terminated after being *mmap*()'ed so that C string functions will
not segfault when reaching the end of the *mmap()*'ed file..

The alternative would have been to *open()* and *mmap()* the *.xml* files in read-write mode (as opposed to read-only) on *)LOAD*, which would have been a little strange.

Note that GNU APL itself (and humans editing them) are the only XML parsers
that understands these *.xml* files. For that reason this minor incompatibility with
the XML standard should be acceptable.

Best Regards,
Jürgen


On 2/3/25 03:27, M.Hall wrote:
Found it.
Looks like XML_Saving_Archive::emit_token_val() line 769 of src/Archive.cc was adding its own close quote.

$ diff -u src/Archive.cc-ORIG src/Archive.cc
--- src/Archive.cc-ORIG 2025-02-02 15:07:35.000000000 -0600
+++ src/Archive.cc 2025-02-02 15:07:24.000000000 -0600
@@ -766,7 +766,7 @@
                          Assert1(fun);
                          save_Function_name(*fun);
                        }
-                       out << "\"";
+//                     out << "\"";
                        break;

         default:       FIXME;

I don't know if this will break anything else.

And the nulls at the end of the XML file (\0 \0 \0 \0 LF) are there on purpose.
Is it still an XML file? (rhetorical question)
--
Mike Hall


Reply via email to