Date: Thu, 8 Mar 2018 22:51:01 -0800 From: Conrad Meyer <cem@freebsd.org> To: Bruce Evans <brde@optusnet.com.au> Cc: Mark Johnston <markj@freebsd.org>, src-committers <src-committers@freebsd.org>, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: Re: svn commit: r330663 - head/sys/kern Message-ID: <CAG6CVpUE8JC5z_gHdzzHmmCuZCkPZ2tCwwQYPgr%2BszQ5hy-kBg@mail.gmail.com> In-Reply-To: <20180309150402.X950@besplex.bde.org> References: <201803081704.w28H4aQx052056@repo.freebsd.org> <20180309150402.X950@besplex.bde.org>
next in thread | previous in thread | raw e-mail | index | archive | help
On Thu, Mar 8, 2018 at 8:42 PM, Bruce Evans <brde@optusnet.com.au> wrote: > On Thu, 8 Mar 2018, Mark Johnston wrote: >> ... >> +++ head/sys/kern/kern_shutdown.c Thu Mar 8 17:04:36 2018 >> (r330663) >> @@ -1115,6 +1115,12 @@ dump_check_bounds(struct dumperinfo *di, off_t >> offset, >> >> if (length != 0 && (offset < di->mediaoffset || >> offset - di->mediaoffset + length > di->mediasize)) { >> + if (di->kdcomp != NULL && offset >= di->mediaoffset) { >> + printf( >> + "Compressed dump failed to fit in device >> boundaries.\n"); >> + return (E2BIG); >> + } >> + > > Style bug: extra blank line. Even the outer if statements in this function > are missing this error. No. Style(9) does not and should not require the complete absence of blank lines. Committers are free to use their best judgement on how to separate blocks of code. I think Mark's decision is eminently reasonable. >> printf("Attempt to write outside dump device >> boundaries.\n" >> "offset(%jd), mediaoffset(%jd), length(%ju), >> mediasize(%jd).\n", >> (intmax_t)offset, (intmax_t)di->mediaoffset, > ... > > Other style bugs: > - capitalization of error messages > - termination of error messages with a period Why do you think these are style bugs? Conrad
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CAG6CVpUE8JC5z_gHdzzHmmCuZCkPZ2tCwwQYPgr%2BszQ5hy-kBg>