ONLYOFFICE / DocumentBuilder

ONLYOFFICE Document Builder is powerful text, spreadsheet, presentation and PDF generating tool
https://www.onlyoffice.com/document-builder.aspx
GNU Affero General Public License v3.0
113 stars 56 forks source link

Allocation failed on `builder.openFile` #13

Closed ShockwaveNN closed 7 years ago

ShockwaveNN commented 7 years ago
  1. Create test.js
    builder.OpenFile("only_paragraph.docx");
    var oDocument = Api.GetDocument();
    var oParagraph;
    oParagraph = oDocument.GetElement(0);
    oParagraph.SetJc("center");
    oParagraph.AddText("Center");
    builder.SaveFile("docx", "only_paragraph.docx");
  2. Place attached only_paragraph.docx in same folder only_paragraph.docx
  3. Run documentbuilder test.js

Result:

<--- Last few GCs --->

    9800 ms: Scavenge 1398.3 (1444.5) -> 1398.3 (1444.5) MB, 28.5 / 0 ms [allocation failure].
    9826 ms: Scavenge 1398.3 (1444.5) -> 1398.3 (1444.5) MB, 25.9 / 0 ms [allocation failure].
    9853 ms: Scavenge 1398.3 (1444.5) -> 1398.3 (1444.5) MB, 26.9 / 0 ms [allocation failure].
    9880 ms: Scavenge 1398.3 (1444.5) -> 1398.3 (1444.5) MB, 27.4 / 0 ms [allocation failure].
    9905 ms: Scavenge 1398.3 (1444.5) -> 1398.3 (1444.5) MB, 24.7 / 0 ms [allocation failure].

<--- JS stacktrace --->
Cannot get stack trace in GC.

#
# Fatal error in MarkCompactCollector: semi-space copy, fallback in old gen

# Allocation failed - process out of memory
#

Illegal instruction (core dumped)

Tested on: Ubuntu 16.04

documentbuilder -v
v5.1.0.5
sdk version:  5.1.0 (build:5)
ShockwaveNN commented 7 years ago

There was some missed commits in v5.1.0.5 Fixed in v5.1.0.7