summaryrefslogtreecommitdiff
path: root/app-cdr/bin2iso/files
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2017-12-30 01:11:30 +0000
committerV3n3RiX <venerix@redcorelinux.org>2017-12-30 01:11:30 +0000
commit76dfef0cec9170000357d2f354e412daf48941fc (patch)
tree56647120c0ee20ab3494475c86722034cd194b02 /app-cdr/bin2iso/files
parentccf84bcd604130256d1377cd58f0a634ae6ee20f (diff)
gentoo resync : 30.12.2017
Diffstat (limited to 'app-cdr/bin2iso/files')
-rw-r--r--app-cdr/bin2iso/files/bin2iso-19b-sanity-checks.patch48
1 files changed, 24 insertions, 24 deletions
diff --git a/app-cdr/bin2iso/files/bin2iso-19b-sanity-checks.patch b/app-cdr/bin2iso/files/bin2iso-19b-sanity-checks.patch
index 5803bc103a86..43e3f4aae3b4 100644
--- a/app-cdr/bin2iso/files/bin2iso-19b-sanity-checks.patch
+++ b/app-cdr/bin2iso/files/bin2iso-19b-sanity-checks.patch
@@ -2,29 +2,29 @@ Add more checks to prevent segfaults in ill-formatted files
http://bugs.gentoo.org/show_bug.cgi?id=90540
---- bin2iso19b_linux.c
-+++ bin2iso19b_linux.c
+--- a/bin2iso19b_linux.c
++++ b/bin2iso19b_linux.c
@@ -237,6 +237,10 @@
- // Get the 'mode'
- if (strncmp(&Line[2], "TRACK ", 6)==0)
- {
-+ if (Line[8] < '0' || Line[8] > '9' || Line[9] < '0' || Line[9] > '9') {
-+ printf("Error: Track # is not a 2 digit number\n");
-+ exit(1);
-+ }
- strncpy(track->num, &Line[8], 2); track->num[2] = '\0';
-
- track->mode = UNKNOWN;
+ // Get the 'mode'
+ if (strncmp(&Line[2], "TRACK ", 6)==0)
+ {
++ if (Line[8] < '0' || Line[8] > '9' || Line[9] < '0' || Line[9] > '9') {
++ printf("Error: Track # is not a 2 digit number\n");
++ exit(1);
++ }
+ strncpy(track->num, &Line[8], 2); track->num[2] = '\0';
+
+ track->mode = UNKNOWN;
@@ -246,7 +250,11 @@
- if(strncmp(&Line[11], "MODE2/2352", 10)==0) track->mode = MODE2_2352;
- if(strncmp(&Line[11], "MODE2/2336", 10)==0) track->mode = MODE2_2336;
- }
-- else return(1);
-+ else
-+ {
-+ printf("Error: 2nd line does not begin with ' TRACK '\n");
-+ exit(1);
-+ }
-
- // Set the name
- strcpy(track->name, sBinFilename);
+ if(strncmp(&Line[11], "MODE2/2352", 10)==0) track->mode = MODE2_2352;
+ if(strncmp(&Line[11], "MODE2/2336", 10)==0) track->mode = MODE2_2336;
+ }
+- else return(1);
++ else
++ {
++ printf("Error: 2nd line does not begin with ' TRACK '\n");
++ exit(1);
++ }
+
+ // Set the name
+ strcpy(track->name, sBinFilename);