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

Diff for /src/usr.bin/mg/file.c between version 1.68 and 1.69

version 1.68, 2008/09/15 16:11:35 version 1.69, 2008/09/15 16:13:35
Line 293 
Line 293 
         char *dp;          char *dp;
   
         if (replacebuf == TRUE)          if (replacebuf == TRUE)
                 x = undo_enable(FALSE);                  x = undo_enable(FFRAND, 0);
         else          else
                 x = undo_enabled();                  x = undo_enabled();
   
Line 335 
Line 335 
                 killbuffer(bp);                  killbuffer(bp);
                 if ((bp = dired_(fname)) == NULL)                  if ((bp = dired_(fname)) == NULL)
                         return (FALSE);                          return (FALSE);
                 undo_enable(x);                  undo_enable(FFRAND, x);
                 curbp = bp;                  curbp = bp;
                 return (showbuffer(bp, curwp, WFFULL | WFMODE));                  return (showbuffer(bp, curwp, WFFULL | WFMODE));
         } else {          } else {
Line 351 
Line 351 
          * We will delete this newline after insertion.           * We will delete this newline after insertion.
          * Disable undo, as we create the undo record manually.           * Disable undo, as we create the undo record manually.
          */           */
         x2 = undo_enable(FALSE);          x2 = undo_enable(FFRAND, 0);
         (void)lnewline();          (void)lnewline();
         olp = lback(curwp->w_dotp);          olp = lback(curwp->w_dotp);
         undo_enable(x2);          undo_enable(FFRAND, x2);
   
         nline = 0;          nline = 0;
         siz = 0;          siz = 0;
Line 477 
Line 477 
         }          }
         bp->b_lines += nline;          bp->b_lines += nline;
 cleanup:  cleanup:
         undo_enable(x);          undo_enable(FFRAND, x);
   
         /* return FALSE if error */          /* return FALSE if error */
         return (s != FIOERR);          return (s != FIOERR);

Legend:
Removed from v.1.68  
changed lines
  Added in v.1.69