diff options
author | Brian Paul <[email protected]> | 2009-12-11 10:04:07 -0700 |
---|---|---|
committer | Brian Paul <[email protected]> | 2009-12-11 10:04:07 -0700 |
commit | a087eb590d780cb82b49464e05ffc85123adce7e (patch) | |
tree | a2ac3ec2cc0b9001b350664d6e7915aba5e087a9 /progs | |
parent | cb640c8d40c4ee34160a14d646c244f44a5013f6 (diff) | |
parent | e128cc205e30540597ecd57849060a6bf4714d9f (diff) |
Merge branch 'mesa_7_7_branch'
Conflicts:
src/gallium/state_trackers/xorg/xorg_xv.c
src/mesa/drivers/dri/intel/intel_span.c
Diffstat (limited to 'progs')
-rw-r--r-- | progs/samples/rgbtoppm.c | 7 | ||||
-rw-r--r-- | progs/util/readtex.c | 7 |
2 files changed, 12 insertions, 2 deletions
diff --git a/progs/samples/rgbtoppm.c b/progs/samples/rgbtoppm.c index 56ca5b0efe9..dcb74228dff 100644 --- a/progs/samples/rgbtoppm.c +++ b/progs/samples/rgbtoppm.c @@ -93,7 +93,12 @@ static ImageRec *ImageOpen(char *fileName) fread(image, 1, 12, image->file); if (swapFlag) { - ConvertShort(&image->imagic, 6); + ConvertShort(&image->imagic, 1); + ConvertShort(&image->type, 1); + ConvertShort(&image->dim, 1); + ConvertShort(&image->xsize, 1); + ConvertShort(&image->ysize, 1); + ConvertShort(&image->zsize, 1); } image->tmp = (unsigned char *)malloc(image->xsize*256); diff --git a/progs/util/readtex.c b/progs/util/readtex.c index 81cb626e911..d1c50a494aa 100644 --- a/progs/util/readtex.c +++ b/progs/util/readtex.c @@ -117,7 +117,12 @@ static rawImageRec *RawImageOpen(const char *fileName) fread(raw, 1, 12, raw->file); if (swapFlag) { - ConvertShort(&raw->imagic, 6); + ConvertShort(&raw->imagic, 1); + ConvertShort(&raw->type, 1); + ConvertShort(&raw->dim, 1); + ConvertShort(&raw->sizeX, 1); + ConvertShort(&raw->sizeY, 1); + ConvertShort(&raw->sizeZ, 1); } raw->tmp = (unsigned char *)malloc(raw->sizeX*256); |