[BACK]Return to roff.c CVS log [TXT][DIR] Up to [local] / src / usr.bin / mandoc

Diff for /src/usr.bin/mandoc/roff.c between version 1.268 and 1.269

version 1.268, 2022/12/26 19:16:02 version 1.269, 2023/10/21 17:10:12
Line 1385 
Line 1385 
                  */                   */
   
                 if (buf->buf[pos] != ec) {                  if (buf->buf[pos] != ec) {
                         if (ec != ASCII_ESC && buf->buf[pos] == '\\') {                          if (buf->buf[pos] == '\\') {
                                 roff_expand_patch(buf, pos, "\\e", pos + 1);                                  roff_expand_patch(buf, pos, "\\e", pos + 1);
                                 pos++;                                  pos++;
                         }                          }
Line 1630 
Line 1630 
                                 cp++;                                  cp++;
                                 break;                                  break;
                         case '\\':                          case '\\':
                                 /*                                  cp[-pairs] = '\\';
                                  * Signal to roff_expand() that an escape  
                                  * sequence resulted from copy-in processing  
                                  * and needs to be checked or interpolated.  
                                  */  
                                 cp[-pairs] = ASCII_ESC;  
                                 newesc = 1;                                  newesc = 1;
                                 pairs++;                                  pairs++;
                                 cp++;                                  cp++;
Line 1692 
Line 1687 
         buf.buf = start;          buf.buf = start;
         buf.sz = strlen(start) + 1;          buf.sz = strlen(start) + 1;
         buf.next = NULL;          buf.next = NULL;
         if (roff_expand(r, &buf, ln, 0, ASCII_ESC) & ROFF_IGN) {          if (roff_expand(r, &buf, ln, 0, '\\') & ROFF_IGN) {
                 free(buf.buf);                  free(buf.buf);
                 buf.buf = mandoc_strdup("");                  buf.buf = mandoc_strdup("");
         }          }

Legend:
Removed from v.1.268  
changed lines
  Added in v.1.269