summaryrefslogtreecommitdiff
path: root/wrppm.c
diff options
context:
space:
mode:
Diffstat (limited to 'wrppm.c')
-rw-r--r--wrppm.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/wrppm.c b/wrppm.c
index 6c6d908..65b927c 100644
--- a/wrppm.c
+++ b/wrppm.c
@@ -43,8 +43,8 @@
/* The word-per-sample format always puts the LSB first. */
#define PUTPPMSAMPLE(ptr,v) \
{ register int val_ = v; \
- *ptr++ = (char) (val_ & 0xFF); \
*ptr++ = (char) ((val_ >> 8) & 0xFF); \
+ *ptr++ = (char) (val_ & 0xFF); \
}
#define BYTESPERSAMPLE 2
#define PPM_MAXVAL ((1<<BITS_IN_JSAMPLE)-1)