[Poppler-bugs] [Bug 5952] PageLabelInfo::indexToLabel prepends UTF-16 BOM

bugzilla-daemon at annarchy.freedesktop.org bugzilla-daemon at annarchy.freedesktop.org
Sun Feb 19 06:47:01 PST 2006


Please do not reply to this email: if you want to comment on the bug, go to    
       
the URL shown below and enter yourcomments there.     
   
https://bugs.freedesktop.org/show_bug.cgi?id=5952          
     

chpe at gnome.org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Summary|GooString::getCString       |PageLabelInfo::indexToLabel
                   |returns UTF-8 with prepended|prepends UTF-16 BOM
                   |UTF-16 BOM                  |




------- Additional Comments From chpe at gnome.org  2006-02-19 06:43 -------
Hmm...

  GooString label;

  switch (prop_id)
    {
    case PROP_LABEL:
      page->document->doc->getCatalog ()->indexToLabel (page->index, &label);
      g_value_set_string (value, label.getCString());

page->document is PopplerDocument
->doc is PDFDoc *
->getCatalog() is Catalog *
and Catalog::indexToLabel takes a GooString not a UGooString, so this is *not* a
problem in the glib layer.

---
I've follow it further down to

PageLabelInfo::indexToLabel
where for index=4 (the fith call when opening the testcase with evince),
line 308: label->append(interval->prefix);
appends the BOM to |label|:

(gdb) x /2x interval->prefix
0x82cf2d0:      0xfe    0xff

so the problem is either that PageLabelInfo::indexToLabel appends the
interval->prefix unconverted, or that it is stored that way in ::prefix in the
first place (

-> back to general ?
          
     
     
--           
Configure bugmail: https://bugs.freedesktop.org/userprefs.cgi?tab=email         
     
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.


More information about the Poppler-bugs mailing list