GRASS on DEC-Alpha: first solutions

Wilhelm Hagg hagg at
Thu Nov 2 07:00:00 EST 1995


the problem using GRASS on Dec-Alpha and other Systems
  ERROR: Can't read from ...
is caused by the following GRASS - bug:
  Line: 125

P__readdev (buf, n)
    char *buf;
    int i;

    P__flushdev ();
    while (n > 0)
  i = read (rfd, buf, n);

  if (i <= 0)
^^^^^^^^^^^^^^|---> Must be: if (i < 0)

      P__errordev ("can't read from");
  buf += i;
  n -= i;

Otherwise the son process (the driver) exits with the above
Errormessage in those cases, where he reads faster than the
other process writes to the pipe between the processes 
establisched by fork.

Change this, and it will work a little better :-)

Wilhelm Hagg, Institute of Photogrammetry and Remote Sensing
Karlsruhe University, Englerstr. 7, D-76128 Karlsruhe
Phone: +49 721 608 4131, Fax: +49 721 69 45 68
Email: hagg at

More information about the grass-user mailing list