diff options
author | Marius <mariausol@gmail.com> | 2011-08-18 17:40:23 +0300 |
---|---|---|
committer | Marius <mariausol@gmail.com> | 2011-08-18 17:40:23 +0300 |
commit | 5463542d926a6ca73d86251154cabc00a9333fa5 (patch) | |
tree | 33c0104835277e96d6b0474466e75963fef16de4 /tex/context/base/lxml-tab.lua | |
parent | ee4f24d635e0db2029f026a1c098ae76d1e537d3 (diff) | |
download | context-5463542d926a6ca73d86251154cabc00a9333fa5.tar.gz |
beta 2011.08.18 16:00
Diffstat (limited to 'tex/context/base/lxml-tab.lua')
-rw-r--r-- | tex/context/base/lxml-tab.lua | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/tex/context/base/lxml-tab.lua b/tex/context/base/lxml-tab.lua index 5c5220cb8..99c7226a8 100644 --- a/tex/context/base/lxml-tab.lua +++ b/tex/context/base/lxml-tab.lua @@ -867,18 +867,15 @@ alternative.</p> function xml.checkbom(root) -- can be made faster if root.ri then - local dt, found = root.dt, false + local dt = root.dt for k=1,#dt do local v = dt[k] if type(v) == "table" and v.special and v.tg == "@pi@" and find(v.dt[1],"xml.*version=") then - found = true - break + return end end - if not found then - insert(dt, 1, { special=true, ns="", tg="@pi@", dt = { "xml version='1.0' standalone='yes'"} } ) - insert(dt, 2, "\n" ) - end + insert(dt, 1, { special=true, ns="", tg="@pi@", dt = { "xml version='1.0' standalone='yes'"} } ) + insert(dt, 2, "\n" ) end end |