/[pcre]/code/trunk/pcretest.c
ViewVC logotype

Diff of /code/trunk/pcretest.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1084 by chpe, Tue Oct 16 15:55:20 2012 UTC revision 1085 by chpe, Tue Oct 16 15:55:32 2012 UTC
# Line 1731  return(result); Line 1731  return(result);
1731    
1732  static int pchar(pcre_uint32 c, FILE *f)  static int pchar(pcre_uint32 c, FILE *f)
1733  {  {
1734    int n;
1735  if (PRINTOK(c))  if (PRINTOK(c))
1736    {    {
1737    if (f != NULL) fprintf(f, "%c", c);    if (f != NULL) fprintf(f, "%c", c);
# Line 1751  if (c < 0x100) Line 1752  if (c < 0x100)
1752      }      }
1753    }    }
1754    
1755  if (f != NULL) fprintf(f, "\\x{%02x}", c);  if (f != NULL) n = fprintf(f, "\\x{%02x}", c);
1756  return (c <= 0x000000ff)? 6 :  return n >= 0 ? n : 0;
        (c <= 0x00000fff)? 7 :  
        (c <= 0x0000ffff)? 8 :  
        (c <= 0x000fffff)? 9 : 10;  
1757  }  }
1758    
1759    

Legend:
Removed from v.1084  
changed lines
  Added in v.1085

  ViewVC Help
Powered by ViewVC 1.1.5