Bug 85022

Summary: FILEOPEN: program shows rtf markup for a particular file
Product: LibreOffice Reporter: Terrence Enger <lo_bugs>
Component: filters and storageAssignee: Not Assigned <libreoffice-bugs>
Status: RESOLVED DUPLICATE    
Severity: normal CC: momonasmon
Priority: medium Keywords: bibisected, regression
Version: 4.4.0.0.alpha0+ Master   
Hardware: x86-64 (AMD64)   
OS: All   
Whiteboard:
Crash report or crash signature: Regression By:
Attachments: bibisect output

Description Terrence Enger 2014-10-14 22:39:22 UTC
To reproduce the problem, download file sig3.dot attached to bug 84965
<https://bugs.freedesktop.org/attachment.cgi?id=107780> and open it
from the command line.  I expect to see the document area starting
with a horizontal line and text "I am primarily assigned to an inbound
call queue. I can attempt".  Instead, Writer shows the rtf markup,
starting

    {\rtf1\ansi\ansicpg1252\deff0\deflang1033\deflangfe1033{\fonttbl{\f0\fswiss\fprq2\fcharset0 Arial;}}
    {\colortbl 

I do not know whether the file in question is valid.  However, if I rename the file to sig3.rtf, it is rendered correctly by

    Version: 4.4.0.0.alpha0+
    Build ID: b80c468e35ee321b5580b42642064f74f9241fb6
    TinderBox: Win-x86@39, Branch:master, Time: 2014-10-14_07:06:12

Without the rename, that version too shows the rtf markup.
Comment 1 Terrence Enger 2014-10-14 22:43:41 UTC
Created attachment 107843 [details]
bibisect output

I did a bibisect in the 43all repository.  Each of the "skip"
versions from ba096f4 on presented a msgbox

   General Error
   General input/output error

except 4e504a2, for which I forgot to run LibreOffice.
Comment 2 Maxim Monastirsky 2014-10-22 08:33:18 UTC
It's again libwpd heuristics. That's because this file includes several 0x96 & 0x97 chars, which are considered as WordPerfect single character function codes. After replacing them all with some ASCII chars, the file opens correctly. The current solution is to give the file the right extension (rtf in this case).

(See also Bug 78731 for a similar issue but regarding variable length function codes. Especially note Bug 78731 comment 6.)

*** This bug has been marked as a duplicate of bug 80016 ***
Comment 3 Robinson Tryon (qubit) 2015-12-15 11:03:12 UTC
Migrating Whiteboard tags to Keywords: (bibisected)
[NinjaEdit]