* Patch for xv 3.01
@ 1994-04-28 15:37 Rob Kooper
0 siblings, 0 replies; only message in thread
From: Rob Kooper @ 1994-04-28 15:37 UTC (permalink / raw)
Hi,
I compiled XV 3.01 on a dec ALPHA and it compiled without a hitch.
Offcourse there is no TIFF support yet. I found a small bug in the code
which read an SGI image file. The following patch should overcome this:
*** /sgi4b/kooper/xv-3.01/xviris.c Wed Apr 27 18:41:42 1994
--- ./xviris.c Wed Apr 27 18:37:33 1994
***************
*** 329,337 ****
long *starttab, *lengthtab;
rlebuflen = 2 * xsize + 10;
! tablen = ysize * zsize * sizeof(long);
! starttab = (long *) malloc(tablen);
! lengthtab = (long *) malloc(tablen);
rledat = (byte *) malloc(rlebuflen);
if (!starttab || !lengthtab || !rledat)
--- 329,337 ----
long *starttab, *lengthtab;
rlebuflen = 2 * xsize + 10;
! tablen = ysize * zsize * 4;
! starttab = (long *) malloc(tablen * (sizeof(long) / 4));
! lengthtab = (long *) malloc(tablen * (sizeof(long) / 4));
rledat = (byte *) malloc(rlebuflen);
if (!starttab || !lengthtab || !rledat)
***************
*** 599,608 ****
/* allocate RLE compression tables & stuff */
rlebuflen = 2*w + 10;
! tablen = h * zsize * sizeof(long);
! starttab = (long *) malloc(tablen);
! lengthtab = (long *) malloc(tablen);
rlebuf = (byte *) malloc(rlebuflen);
lumbuf = (byte *) malloc(w * 4);
--- 599,608 ----
/* allocate RLE compression tables & stuff */
rlebuflen = 2*w + 10;
! tablen = h * zsize * 4;
! starttab = (long *) malloc(tablen * (sizeof(long) / 4));
! lengthtab = (long *) malloc(tablen * (sizeof(long) / 4));
rlebuf = (byte *) malloc(rlebuflen);
lumbuf = (byte *) malloc(w * 4);
Rob
-Rob Kooper (kooper@cc.gatech.edu)
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~1994-04-28 15:37 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
1994-04-28 15:37 Patch for xv 3.01 Rob Kooper
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox