aboutsummaryrefslogtreecommitdiff
path: root/sysutils/mkisofs
diff options
context:
space:
mode:
authorJoerg Wunsch <joerg@FreeBSD.org>1997-05-05 14:19:10 +0000
committerJoerg Wunsch <joerg@FreeBSD.org>1997-05-05 14:19:10 +0000
commitca01692fea21bb0a51febaae50b9fce130647245 (patch)
tree6fa92d889b032dd2d428c0406b185921ea970773 /sysutils/mkisofs
parente69c53394559cef020eb2a39c66a8d9a6e4cfce3 (diff)
downloadports-ca01692fea21bb0a51febaae50b9fce130647245.tar.gz
ports-ca01692fea21bb0a51febaae50b9fce130647245.zip
Fix a gross bug in the El Torito stuff, causing a coredump during exit().
Notes
Notes: svn path=/head/; revision=6414
Diffstat (limited to 'sysutils/mkisofs')
-rw-r--r--sysutils/mkisofs/files/patch-ad21
1 files changed, 21 insertions, 0 deletions
diff --git a/sysutils/mkisofs/files/patch-ad b/sysutils/mkisofs/files/patch-ad
new file mode 100644
index 000000000000..f7f28be83269
--- /dev/null
+++ b/sysutils/mkisofs/files/patch-ad
@@ -0,0 +1,21 @@
+--- eltorito.c.orig Mon May 5 15:46:11 1997
++++ eltorito.c Mon May 5 16:11:42 1997
+@@ -33,6 +33,9 @@
+ #include "mkisofs.h"
+ #include "iso9660.h"
+
++#undef MIN
++#define MIN(a, b) (((a) < (b))? (a): (b))
++
+ static struct eltorito_validation_entry valid_desc;
+ static struct eltorito_defaultboot_entry default_desc;
+
+@@ -158,7 +161,7 @@
+ * but who really reads this stuff!
+ */
+ if (publisher)
+- memcpy_max(valid_desc.id, publisher, strlen(publisher));
++ memcpy_max(valid_desc.id, publisher, MIN(31, strlen(publisher)));
+
+ valid_desc.key1[0] = 0x55;
+ valid_desc.key2[0] = 0xAA;