summaryrefslogtreecommitdiff
path: root/fitz/fitz-internal.h
diff options
context:
space:
mode:
Diffstat (limited to 'fitz/fitz-internal.h')
-rw-r--r--fitz/fitz-internal.h20
1 files changed, 20 insertions, 0 deletions
diff --git a/fitz/fitz-internal.h b/fitz/fitz-internal.h
index 22947cf4..24895591 100644
--- a/fitz/fitz-internal.h
+++ b/fitz/fitz-internal.h
@@ -799,6 +799,26 @@ static inline int fz_is_eof_bits(fz_stream *stm)
return fz_is_eof(stm) && (stm->avail == 0 || stm->bits == EOF);
}
+static inline int fz_write_int32be(fz_output *out, int x)
+{
+ char data[4];
+
+ data[0] = x>>24;
+ data[1] = x>>16;
+ data[2] = x>>8;
+ data[3] = x;
+
+ return fz_write(out, data, 4);
+}
+
+static inline void
+fz_write_byte(fz_output *out, int x)
+{
+ char data = x;
+
+ fz_write(out, &data, 1);
+}
+
/*
* Data filters.
*/