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

Diff for /src/usr.bin/sdiff/sdiff.c between version 1.15 and 1.16

version 1.15, 2006/02/15 15:27:38 version 1.16, 2006/02/20 08:29:44
Line 753 
Line 753 
         if (SIMPLEQ_EMPTY(&diffhead))          if (SIMPLEQ_EMPTY(&diffhead))
                 return;                  return;
   
         divc = '\0';          /* Remember the divider. */
           divc = SIMPLEQ_FIRST(&diffhead)->div;
   
         left = NULL;          left = NULL;
         right = NULL;          right = NULL;
         /*          /*
Line 762 
Line 764 
          */           */
         SIMPLEQ_FOREACH(diffp, &diffhead, diffentries) {          SIMPLEQ_FOREACH(diffp, &diffhead, diffentries) {
                 /*                  /*
                  * Make sure that divc is consistent throughout set.  
                  * If divc is set, compare to next entry's divc.  They  
                  * should be the same.  If divc is not set, then store  
                  * this as this set's divc.  
                  */  
                 if (divc == '\0')  
                         divc = diffp->div;  
   
                 /*  
                  * Print changed lines if -s was given,                   * Print changed lines if -s was given,
                  * print all lines if -s was not given.                   * print all lines if -s was not given.
                  */                   */
                 if (!sflag || divc == '|' || divc == '<' || divc == '>')                  if (!sflag || diffp->div == '|' || diffp->div == '<' ||
                       diffp->div == '>')
                         println(diffp->left, diffp->div, diffp->right);                          println(diffp->left, diffp->div, diffp->right);
   
                 /* Append new lines to diff set. */                  /* Append new lines to diff set. */

Legend:
Removed from v.1.15  
changed lines
  Added in v.1.16