[comp.os.minix] Unofficial! patch on ST 1.5 patch 3; only if you have >1 hard disk

meulenbr@cst.philips.nl (Frans Meulenbroeks) (10/18/90)

Hi,

The fs changes in patch 3 contain a bug. The problem is in fs/device.c.
In function dev_close dev_mess.DEVICE was not initialised.
The following cdiff corrects it.

This is NOT an official patch! The official version of this will be in patch 4
which will be released in a month or so. 

There is no need to apply this patch right away unless you have more
than one hard disk. 

Frans.

#!/bin/sh
# This is a shell archive (shar 3.41)
# made 10/18/1990 07:35 UTC by meulenbr@cstw68
# Source directory /vol/minix/frans
#
# existing files will NOT be overwritten unless -c is specified
#
# This shar contains:
# length  mode       name
# ------ ---------- ------------------------------------------
#    316 -rw-r--r-- device.cdiff
#
# ============= device.cdiff ==============
if test -f 'device.cdiff' -a X"$1" != X"-c"; then
	echo 'x - skipping device.cdiff (File already exists)'
else
echo 'x - extracting device.cdiff (Text)'
sed 's/^X//' << 'SHAR_EOF' > device.cdiff &&
*** prev/fs/device.c	Sat Oct  6 22:37:48 1990
--- new/fs/device.c	Wed Oct 17 23:27:00 1990
***************
*** 54,59 ****
--- 54,60 ----
X  /* This procedure can be used when a special file needs to be closed. */
X  
X    find_dev(dev);
+   dev_mess.DEVICE = dev;
X    (*dmap[major].dmap_close)(task, &dev_mess);
X  }
X  
SHAR_EOF
chmod 0644 device.cdiff ||
echo 'restore of device.cdiff failed'
Wc_c="`wc -c < device.cdiff`"
test 316 -eq "$Wc_c" ||
	echo 'device.cdiff: original size 316, current size' "$Wc_c"
fi
exit 0
--
Frans Meulenbroeks        (meulenbr@cst.philips.nl)
	Centre for Software Technology
	( or try: ...!mcsun!phigate!prle!cst!meulenbr)