summaryrefslogtreecommitdiff
path: root/devel/entity/files/patch-libentitynjs_iostream.c
diff options
context:
space:
mode:
authorJohan van Selst <johans@FreeBSD.org>2007-10-12 08:31:11 +0000
committerJohan van Selst <johans@FreeBSD.org>2007-10-12 08:31:11 +0000
commit8c2897a3fe4b4dedf696768d44abd96ca77d352b (patch)
tree20e088cc101718bdff3f364c679cc5c5b02c5cb5 /devel/entity/files/patch-libentitynjs_iostream.c
parentUpdate to 1.31.4 (distversion 1.314) (diff)
- Fix build with gcc 4.2
- While we're here, replace manual ${LDCONFIG} command with ${USE_LDCONFIG}
Notes
Notes: svn path=/head/; revision=201354
Diffstat (limited to 'devel/entity/files/patch-libentitynjs_iostream.c')
-rw-r--r--devel/entity/files/patch-libentitynjs_iostream.c42
1 files changed, 42 insertions, 0 deletions
diff --git a/devel/entity/files/patch-libentitynjs_iostream.c b/devel/entity/files/patch-libentitynjs_iostream.c
new file mode 100644
index 000000000000..1f5c30f81d39
--- /dev/null
+++ b/devel/entity/files/patch-libentitynjs_iostream.c
@@ -0,0 +1,42 @@
+--- libentitynjs/iostream.c.orig 2007-10-12 10:20:45.000000000 +0200
++++ libentitynjs/iostream.c 2007-10-12 10:17:41.000000000 +0200
+@@ -205,8 +205,9 @@ js_iostream_pipe (FILE *fp, int readp)
+
+
+ size_t
+-js_iostream_read (JSIOStream *stream, void *ptr, size_t size)
++js_iostream_read (JSIOStream *stream, void *vptr, size_t size)
+ {
++ unsigned char *ptr = (unsigned char *)vptr;
+ size_t total = 0;
+ int got;
+
+@@ -233,7 +234,7 @@ js_iostream_read (JSIOStream *stream, vo
+
+ stream->bufpos += got;
+ size -= got;
+- (unsigned char *) ptr += got;
++ ptr += got;
+ total += got;
+ }
+ else
+@@ -251,8 +252,9 @@ js_iostream_read (JSIOStream *stream, vo
+
+
+ size_t
+-js_iostream_write (JSIOStream *stream, void *ptr, size_t size)
++js_iostream_write (JSIOStream *stream, void *vptr, size_t size)
+ {
++ unsigned char *ptr = (unsigned char *)vptr;
+ int space;
+ size_t total = 0;
+
+@@ -290,7 +292,7 @@ js_iostream_write (JSIOStream *stream, v
+ stream->data_in_buf += space;
+ total += space;
+ size -= space;
+- (unsigned char *) ptr += space;
++ ptr += space;
+
+ /* Now the buffer contains buffered write data. */
+ stream->writep = 1;