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

Diff for /src/usr.bin/less/line.c between version 1.32 and 1.33

version 1.32, 2019/08/31 13:44:29 version 1.33, 2019/09/03 23:08:42
Line 46 
Line 46 
 static int attr_ewidth(int);  static int attr_ewidth(int);
 static int do_append(LWCHAR, char *, off_t);  static int do_append(LWCHAR, char *, off_t);
   
 extern volatile sig_atomic_t sigs;  
 extern int bs_mode;  extern int bs_mode;
 extern int linenums;  extern int linenums;
 extern int ctldisp;  extern int ctldisp;
Line 685 
Line 684 
                         mbc_buf[mbc_buf_index++] = c;                          mbc_buf[mbc_buf_index++] = c;
                         memset(&mbs, 0, sizeof(mbs));                          memset(&mbs, 0, sizeof(mbs));
                         sz = mbrtowc(&ch, mbc_buf, mbc_buf_index, &mbs);                          sz = mbrtowc(&ch, mbc_buf, mbc_buf_index, &mbs);
   
                         /* Incomplete UTF-8: wait for more bytes. */                          /* Incomplete UTF-8: wait for more bytes. */
                         if (sz == (size_t)-2)                          if (sz == (size_t)-2)
                                 return (0);                                  return (0);
Line 1034 
Line 1033 
   
         n = 0;          n = 0;
         for (;;) {          for (;;) {
                 if (c == '\n' || c == EOI || ABORT_SIGS()) {                  if (c == '\n' || c == EOI || abort_sigs()) {
                         new_pos = ch_tell();                          new_pos = ch_tell();
                         break;                          break;
                 }                  }
Line 1077 
Line 1076 
         linebuf[--n] = '\0';          linebuf[--n] = '\0';
         for (;;) {          for (;;) {
                 c = ch_back_get();                  c = ch_back_get();
                 if (c == '\n' || ABORT_SIGS()) {                  if (c == '\n' || abort_sigs()) {
                         /*                          /*
                          * This is the newline ending the previous line.                           * This is the newline ending the previous line.
                          * We have hit the beginning of the line.                           * We have hit the beginning of the line.

Legend:
Removed from v.1.32  
changed lines
  Added in v.1.33