From kleiweg@let.rug.nl  Sat Dec 23 09:21:04 2000
From: kleiweg@let.rug.nl (kleiweg@let.rug.nl)
Date: Sat, 23 Dec 2000 10:21:04 +0100 (MET)
Subject: [Rd] (HP-UX) scan: last line gets duplicated (PR#790)
Message-ID: <200012230921.KAA14843@pubhealth.ku.dk>

Peter Kleiweg skriver...

> > > Prof Brian D Ripley wrote:

> > > > This bug PR#672, also reported from your institution.

The bug fix I mailed yesterday does fix the bug, but also
introduces a new one: requested trimming of trailing white space
doesn't happen anymore. Here is a correct patch:


*** src/main/scan.c	Sat Dec  2 19:42:25 2000
--- src/main/scan.c.new	Sat Dec 23 10:02:34 2000
***************
*** 240,246 ****
      }
   donefill:
      if (strip) {
! 	while (isspace((int)*--bufp))
  	    ;
  	bufp++;
      }
--- 240,246 ----
      }
   donefill:
      if (strip) {
! 	while (--bufp >= buffer && isspace((int)*bufp))
  	    ;
  	bufp++;
      }


-- 
Er liep twee kg



-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-devel mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-devel-request@stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._


[Rd] (HP-UX) scan: last line gets duplicated (PR#790)
kleiweg@let.rug.nl