Re: possible unionfs bug

2003-07-23 Thread David Schultz
On Sun, Jul 20, 2003, Divacky Roman wrote:
> Hi,
> 
> I might be wrong but this:
> 
> free(mp->mnt_data, M_UNIONFSMNT);   /* XXX */
>   mp->mnt_data = 0;
>   
> seems to me wrong and might cause crashes etc.
> am I correct or wrong?
> 
> its from union_vfsops.c:384

What's wrong with it?  It's just freeing the memory it allocated
earlier.  FFS does the same thing.
___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: possible unionfs bug

2003-07-20 Thread Pawel Jakub Dawidek
On Sun, Jul 20, 2003 at 03:02:21PM +0200, Divacky Roman wrote:
+> I might be wrong but this:
+> 
+> free(mp->mnt_data, M_UNIONFSMNT);   /* XXX */
+>  mp->mnt_data = 0;
+>  
+> seems to me wrong and might cause crashes etc.
+> am I correct or wrong?

Could you describe scenario when this could be dangerous? Or why do you
think it is?

This memory is allocated while mounting unionfs file system,
so it is quite natural to free this memory while unmounting file system.

-- 
Pawel Jakub Dawidek   [EMAIL PROTECTED]
UNIX Systems Programmer/Administrator http://garage.freebsd.pl
Am I Evil? Yes, I Am! http://cerber.sourceforge.net


pgp0.pgp
Description: PGP signature


possible unionfs bug

2003-07-20 Thread Divacky Roman
Hi,

I might be wrong but this:

free(mp->mnt_data, M_UNIONFSMNT);   /* XXX */
mp->mnt_data = 0;

seems to me wrong and might cause crashes etc.
am I correct or wrong?

its from union_vfsops.c:384

thnx

Roman Divacky
___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to "[EMAIL PROTECTED]"