NetBSD-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: bin/54222: mount_portal(8) invalid free() after src/sbin/mount_portal/puffs_portal.c,-r1.9

The following reply was made to PR bin/54222; it has been noted by GNATS.

From: Robert Elz <kre%munnari.OZ.AU@localhost>
Subject: Re: bin/54222: mount_portal(8) invalid free() after src/sbin/mount_portal/puffs_portal.c,-r1.9
Date: Thu, 23 May 2019 18:06:06 +0700

     Date:        Thu, 23 May 2019 10:05:01 +0000 (UTC)
     From:        Leonardo Taccari <>
     Message-ID:  <>
   |  Thank you!  I can confirm that by avoiding calling portal_node_reclaim()
   |  in portal_node_getattr() and inlining relevant lines instead fixes
   |  the problem reported (for completeness patch attached).
 Yes, I had done that myself, and ...
 The patch needed is (I think - or at least, without really understanding
 enough about the underlying operations, to be ultra safe) that it needs
 to be a little more complicated that that simple version.   Eventually
 someone who understands this stuff well can work out if my extra
 complications are needed, and if not, rip them out.
   |  However, the results can be a bit surprising.
 Yes, I saw that as well (cat worked, head/sed/awk/...) did not.
 I have fixes for that as well.
 All is still not good however, ls (and similar, stat, ...) show
 what should be directories as if they were files.  In general the
 file type isn't really getting passed back correctly, and so far
 I have not worked out why.
 I think I will commit what I have so far, and then keep trying to
 see if the file type issue can get fixed.
 These fixes probably ought to be pulled up to -8 (whether before
 or after 8.1 isn't my decision to make, fortunately) - but I can't
 really test this stuff on -8 (my kernels don't generally have
 PUFFS enabled, so to test this on current I had to make a special
 kernel config).   So, if these changes are to get pulled up,
 someone else will need to test them in -8 (shouldn't be hard to
 apply, doesn't look as if any of the relevant code has been touched
 in years) and make the request.

Home | Main Index | Thread Index | Old Index