Re: svn commit: r328346 - in head/sys: fs/ext2fs ufs/ffs ufs/ufs

2018-01-27 Thread Pedro Giffuni
On 01/27/18 11:14, Warner Losh wrote: On Jan 27, 2018 8:17 AM, "Pedro Giffuni" > wrote: On 01/26/18 06:36, Bruce Evans wrote: On Thu, 25 Jan 2018, Pedro Giffuni wrote: On 25/01/2018 14:24, Bruce Evans wrote:

Re: svn commit: r328346 - in head/sys: fs/ext2fs ufs/ffs ufs/ufs

2018-01-27 Thread Warner Losh
On Jan 27, 2018 8:17 AM, "Pedro Giffuni" wrote: On 01/26/18 06:36, Bruce Evans wrote: > On Thu, 25 Jan 2018, Pedro Giffuni wrote: > > On 25/01/2018 14:24, Bruce Evans wrote: >> >>> ... >>> This code only works because (if?) nfs is the only caller and nfs never >>> passes

Re: svn commit: r328346 - in head/sys: fs/ext2fs ufs/ffs ufs/ufs

2018-01-27 Thread Pedro Giffuni
On 01/26/18 06:36, Bruce Evans wrote: On Thu, 25 Jan 2018, Pedro Giffuni wrote: On 25/01/2018 14:24, Bruce Evans wrote: ... This code only works because (if?) nfs is the only caller and nfs never passes insane values. I am starting to think that we should simply match uio_resid and set

Re: svn commit: r328346 - in head/sys: fs/ext2fs ufs/ffs ufs/ufs

2018-01-27 Thread Bruce Evans
On Fri, 26 Jan 2018, Pedro Giffuni wrote: On 01/26/18 06:36, Bruce Evans wrote: On Thu, 25 Jan 2018, Pedro Giffuni wrote: On 25/01/2018 14:24, Bruce Evans wrote: ... This code only works because (if?) nfs is the only caller and nfs never passes insane values. I am starting to think that

Re: svn commit: r328346 - in head/sys: fs/ext2fs ufs/ffs ufs/ufs

2018-01-26 Thread Pedro Giffuni
On 01/26/18 06:36, Bruce Evans wrote: On Thu, 25 Jan 2018, Pedro Giffuni wrote: On 25/01/2018 14:24, Bruce Evans wrote: ... This code only works because (if?) nfs is the only caller and nfs never passes insane values. I am starting to think that we should simply match uio_resid and set

Re: svn commit: r328346 - in head/sys: fs/ext2fs ufs/ffs ufs/ufs

2018-01-26 Thread Bruce Evans
On Thu, 25 Jan 2018, Pedro Giffuni wrote: On 25/01/2018 14:24, Bruce Evans wrote: ... This code only works because (if?) nfs is the only caller and nfs never passes insane values. I am starting to think that we should simply match uio_resid and set it to ssize_t. Returning the value to

Re: svn commit: r328346 - in head/sys: fs/ext2fs ufs/ffs ufs/ufs

2018-01-25 Thread Pedro Giffuni
On 25/01/2018 14:24, Bruce Evans wrote: On Thu, 25 Jan 2018, Pedro Giffuni wrote: This is almost unreadable due to hard-coded UTF-8 (mostly for tabs corrupted to spaces) even in previously-literally quoted C code. Mailer agents ... they all suck :( On 01/25/18 11:28, Bruce Evans wrote:

Re: svn commit: r328346 - in head/sys: fs/ext2fs ufs/ffs ufs/ufs

2018-01-25 Thread Bruce Evans
On Thu, 25 Jan 2018, Pedro Giffuni wrote: This is almost unreadable due to hard-coded UTF-8 (mostly for tabs corrupted to spaces) even in previously-literally quoted C code. On 01/25/18 11:28, Bruce Evans wrote: On Wed, 24 Jan 2018, Pedro F. Giffuni wrote: [... Most unreadable lines

Re: svn commit: r328346 - in head/sys: fs/ext2fs ufs/ffs ufs/ufs

2018-01-25 Thread Pedro Giffuni
On 01/25/18 11:28, Bruce Evans wrote: On Wed, 24 Jan 2018, Pedro F. Giffuni wrote: Log:  ext2fs|ufs:Unsign some values related to allocation.  When allocating memory through malloc(9), we always expect the amount of  memory requested to be unsigned as a negative value would either stand

Re: svn commit: r328346 - in head/sys: fs/ext2fs ufs/ffs ufs/ufs

2018-01-25 Thread Bruce Evans
On Wed, 24 Jan 2018, Pedro F. Giffuni wrote: Log: ext2fs|ufs:Unsign some values related to allocation. When allocating memory through malloc(9), we always expect the amount of memory requested to be unsigned as a negative value would either stand for an error or an overflow. Unsign some

svn commit: r328346 - in head/sys: fs/ext2fs ufs/ffs ufs/ufs

2018-01-24 Thread Pedro F. Giffuni
Author: pfg Date: Wed Jan 24 17:58:48 2018 New Revision: 328346 URL: https://svnweb.freebsd.org/changeset/base/328346 Log: ext2fs|ufs:Unsign some values related to allocation. When allocating memory through malloc(9), we always expect the amount of memory requested to be unsigned as a