[10/12] fix handling of '/' embedded in filenames in isofs

From: William Lee Irwin III
Date: Sun Jun 13 2004 - 19:54:04 EST


* Fix slashes in broken Acorn ISO9660 images in fs/isofs/dir.c (Darren Salt)
This fixes Debian BTS #141660.
http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=141660

From: Darren Salt <linux@xxxxxxxxxxxxxxxxxxxxxxxxxxx>
Message-ID: <4B238BA09A%linux@xxxxxxxxxxxxxxxxxxxxxxxxxxx>
To: submit@xxxxxxxxxxxxxxx
Subject: Handle '/' in filenames in broken ISO9660 images

[Also applicable to 2.2.x]

There has been for some time a problem with certain CD-ROMs whose images were
generated using a particular tool on Acorn RISC OS. The problem is that in
certain catalogue entries, the extension separator character '/' (RISC OS
uses '.' and '/' the other way round) was not replaced with '.'; thus Linux
cannot properly parse this without this patch, thinking that it is a
directory separator.

Index: linux-2.5/fs/isofs/dir.c
===================================================================
--- linux-2.5.orig/fs/isofs/dir.c 2004-06-13 11:57:34.000000000 -0700
+++ linux-2.5/fs/isofs/dir.c 2004-06-13 12:08:57.000000000 -0700
@@ -64,7 +64,8 @@
break;

/* Convert remaining ';' to '.' */
- if (c == ';')
+ /* Also '/' to '.' (broken Acorn-generated ISO9660 images) */
+ if (c == ';' || c == '/')
c = '.';

new[i] = c;
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/