WinMerge htm files attached to issues cause the browser to hang when opened in the code viewer

XMLWordPrintable

    • 1
    • Severity 3 - Minor

      Issue Summary

      WinMerge htm files attached to issues cause the browser to hang when opened in the code viewer

      Steps to Reproduce

      • Use the WinMerge application to compare two large XML files, each over 1MB in size.
      • Generate a report in HTM format.
      • Attach the HTM file to the issue.
      • Attempt to open the attachment in the code viewer by clicking on it.

      Expected Results

      The htm file can be opened in the viewer as plain text

      Actual Results

      Browser hangs trying to parse the data in the htm file.

      The htm file generated has a complex structure intended to represent some XML data styled with HTML for display purposes within a table. However, the code is excessively long and contains numerous HTML encodings in a single line of 118,962 chars. This makes the code viewer try to parse the information and hang. 

      The following snippet is part of the line of code responsible for the hang. Please note that this is not the complete line. A lot of chars are replaced by dots. 

      <td class="ln"><a id="d3" href="#d3">.</a></td><td style="color: #000000; background-color: #efcb05; "><code><span style="color: #000000; background-color: #efcb05; ">&nbsp; &nbsp; </span><span style="color: #000000; background-color: #efcb05; ">&lt;FO&gt;</span>..........................................<span style="color: #000000; background-color: #efcb05; ">IF THE XXXXXXXX XXXX Done&amp;#xD;</span></code></td>

      Workaround

      Zip the htm file and attach to issue. This makes it easy to download the file and then use it as required. 

        1. hang.png
          51 kB
          Zee Choudhry

            Assignee:
            Unassigned
            Reporter:
            Zee Choudhry (Inactive)
            Votes:
            1 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated: