add directory Minix
This commit is contained in:
50
Minix/2.0.0/fixes/fix-3
Normal file
50
Minix/2.0.0/fixes/fix-3
Normal file
@@ -0,0 +1,50 @@
|
||||
This fix repairs a bug in a routine in the isoread command that matches
|
||||
filenames. The exact nature of the bug has been lost in the mist of time,
|
||||
but it is for certain that isoread works badly without this fix.
|
||||
|
||||
To apply this this do the following as bin:
|
||||
|
||||
! cd /usr
|
||||
! patch -p0 < "this-file"
|
||||
! cd src/commands/simple
|
||||
! make install
|
||||
|
||||
You will find the original isoread.c file renamed to isoread.c~ in
|
||||
src/commands/simple/. You may wish to delete it to clean things up.
|
||||
|
||||
diff -c -r /save/std/2.0.0/src/commands/simple/isoread.c ./src/commands/simple/isoread.c
|
||||
*** /save/std/2.0.0/src/commands/simple/isoread.c Mon Aug 07 20:33:32 1995
|
||||
--- ./src/commands/simple/isoread.c Sat Nov 16 12:15:41 1996
|
||||
***************
|
||||
*** 175,187 ****
|
||||
int dir_flag;
|
||||
{
|
||||
int i;
|
||||
|
||||
/* First match the filename */
|
||||
! for (i = 0; (i < strlen(name) && i < iso_711(dir_ptr->name_length)); i++)
|
||||
{
|
||||
! if (dir_ptr->name[i] == ';') break;
|
||||
if (name[i] != LOWER_CASE(dir_ptr->name[i])) return 1;
|
||||
}
|
||||
|
||||
/* The filename is ok, now look at the file type */
|
||||
if (dir_flag && !IS_DIR(dir_ptr)) return 1; /* File type not correct */
|
||||
--- 175,191 ----
|
||||
int dir_flag;
|
||||
{
|
||||
int i;
|
||||
+ int len;
|
||||
|
||||
/* First match the filename */
|
||||
! len = strlen(name);
|
||||
! if (len > iso_711(dir_ptr->name_length)) return 1;
|
||||
! for (i = 0; i < len; i++)
|
||||
{
|
||||
! if (dir_ptr->name[i] == ';') return 1;
|
||||
if (name[i] != LOWER_CASE(dir_ptr->name[i])) return 1;
|
||||
}
|
||||
+ if (dir_ptr->name[i] != ';' && dir_ptr->name[i] != 0) return 1;
|
||||
|
||||
/* The filename is ok, now look at the file type */
|
||||
if (dir_flag && !IS_DIR(dir_ptr)) return 1; /* File type not correct */
|
||||
Reference in New Issue
Block a user