diff options
author | joerg <joerg@FreeBSD.org> | 1997-05-05 22:19:10 +0800 |
---|---|---|
committer | joerg <joerg@FreeBSD.org> | 1997-05-05 22:19:10 +0800 |
commit | 4c8f462fac8f689e2631c8400c7a851d0d31f1e0 (patch) | |
tree | 481e374b127ab6e4f99307d35c4f96c000e219a8 /sysutils/mkisofs | |
parent | e1805fec568d49d2053ed2a0b83a9fd0d8a46414 (diff) | |
download | freebsd-ports-gnome-4c8f462fac8f689e2631c8400c7a851d0d31f1e0.tar.gz freebsd-ports-gnome-4c8f462fac8f689e2631c8400c7a851d0d31f1e0.tar.zst freebsd-ports-gnome-4c8f462fac8f689e2631c8400c7a851d0d31f1e0.zip |
Fix a gross bug in the El Torito stuff, causing a coredump during exit().
Diffstat (limited to 'sysutils/mkisofs')
-rw-r--r-- | sysutils/mkisofs/files/patch-ad | 21 |
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; |