You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
libraw1394/libraw1394-juju-munmap-corr...

22 lines
854 B

diff -Naurp libraw1394-1.3.0/juju/raw1394-iso.c libraw1394-1.3.0.fix/juju/raw1394-iso.c
--- libraw1394-1.3.0/juju/raw1394-iso.c 2008-04-28 13:57:30.000000000 -0400
+++ libraw1394-1.3.0.fix/juju/raw1394-iso.c 2008-04-28 14:06:21.000000000 -0400
@@ -421,7 +421,7 @@ iso_init(raw1394handle_t handle, int typ
}
handle->iso.buffer =
- mmap(NULL, buf_packets * max_packet_size,
+ mmap(NULL, buf_packets * handle->iso.max_packet_size,
prot, MAP_SHARED, handle->iso.fd, 0);
if (handle->iso.buffer == MAP_FAILED) {
@@ -432,7 +432,7 @@ iso_init(raw1394handle_t handle, int typ
}
handle->iso.buffer_end = handle->iso.buffer +
- buf_packets * max_packet_size;
+ buf_packets * handle->iso.max_packet_size;
handle->iso.head = handle->iso.buffer;
handle->iso.tail = handle->iso.buffer;
handle->iso.first_payload = handle->iso.buffer;