• Tushar Bende's avatar
    fdo#78469 FileCorrupt:During export LO was adding wrong tags inside <w:sdtPr> · 1fc9923b
    Tushar Bende yazdı
    Description :
    Docx file corrupt after roundtrip.
    Root cause: For some documents During export LO was not checking for the content of sdt and Even if sdt contains Drawing object
    LO was writing text data related tags <w:text/> & <w:dataBinding> in <w:sdtPr>,This was the reason for corruption.
    
    To Fix this checking is there is any Drawing Object in run if yes skip writing <w:dataBinding> tag in <w:sdtPr>
    And if sdt content is Text and Drawing both do not write <Text> or <Picture> as these tags will again result in corruption.
    
    Presently, while writing the sdtContent tag LO does not check for the content type due to which LO ends up adding the dataBinding along with the
    Drawing/AlternateContent which is incorrect according ecma ECMA-376, Second Edition, Part 1 : 17.5.2.6. This cause in file corruption.
    
    Added a check to restrict the aforementioned.
    
    Reviewed on:
    	https://gerrit.libreoffice.org/9371
    
    Change-Id: Id31437db0309b0a2159389a4a9a1f5e13c1ac3a5
    1fc9923b