From owner-svn-src-all@freebsd.org Fri Mar 9 06:51:05 2018 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id DA054F31976; Fri, 9 Mar 2018 06:51:04 +0000 (UTC) (envelope-from cse.cem@gmail.com) Received: from mail-it0-f46.google.com (mail-it0-f46.google.com [209.85.214.46]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 7794686DC3; Fri, 9 Mar 2018 06:51:03 +0000 (UTC) (envelope-from cse.cem@gmail.com) Received: by mail-it0-f46.google.com with SMTP id u5-v6so1651553itc.1; Thu, 08 Mar 2018 22:51:03 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:reply-to:in-reply-to:references :from:date:message-id:subject:to:cc; bh=CUVrkfr91OtOGlK3UCzmYNParbgvLwrIVNB/iKGiusE=; b=VoxUx0yvC0tJljlhld9eey6xpZeCN9k/KA2FXCeR2SFmqqvJxAQVEX3Hbzq5SGlaZ2 39C5D/PrPy6Hl9gtehXXbPqxhPNFDgbwRIYHeNCREhXa1L8qCkEK0zK59HgtbObPMi5u PSn22Cz2spufraDKEqyEGzJ1BSZzIoj4EhzYm+d0hLJT7OEtQdyvvcJZ7Jqm/nrkPOJm usNSFRB9V396z5oCQj8VRoBLkyoTDMr2a+MZ2kSLW0l1+wYqpoatE8LzE8pQ0IY2EZsG MnZ5j2ke19X2JkG/I20KGLATJIfL0BAizjCWpswWK16ddnfweOXOwy71h6EKARyWGH6Q CoOQ== X-Gm-Message-State: AElRT7FqsrJXKEzZ5upVlqdPgVmDJDfEgFo5aVbRy9tSLhKoTEgBb6lB 0E+7OuistA7hw6h8ezo3p056nB6z X-Google-Smtp-Source: AG47ELsgpZsQe+NkaB+8QwWBLqAzoI308eSNEXEyWt2u7ItvRIFglaIqQjVA8TYuKVdqMOje3Pmdsw== X-Received: by 2002:a24:2e4e:: with SMTP id i75-v6mr2011432ita.96.1520578262946; Thu, 08 Mar 2018 22:51:02 -0800 (PST) Received: from mail-it0-f45.google.com (mail-it0-f45.google.com. [209.85.214.45]) by smtp.gmail.com with ESMTPSA id e102sm313071ioj.87.2018.03.08.22.51.02 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 08 Mar 2018 22:51:02 -0800 (PST) Received: by mail-it0-f45.google.com with SMTP id u66so1603582ith.1; Thu, 08 Mar 2018 22:51:02 -0800 (PST) X-Received: by 10.36.161.2 with SMTP id y2mr2073453ite.53.1520578261880; Thu, 08 Mar 2018 22:51:01 -0800 (PST) MIME-Version: 1.0 Reply-To: cem@freebsd.org Received: by 10.2.30.149 with HTTP; Thu, 8 Mar 2018 22:51:01 -0800 (PST) In-Reply-To: <20180309150402.X950@besplex.bde.org> References: <201803081704.w28H4aQx052056@repo.freebsd.org> <20180309150402.X950@besplex.bde.org> From: Conrad Meyer Date: Thu, 8 Mar 2018 22:51:01 -0800 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: svn commit: r330663 - head/sys/kern To: Bruce Evans Cc: Mark Johnston , src-committers , svn-src-all@freebsd.org, svn-src-head@freebsd.org Content-Type: text/plain; charset="UTF-8" X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 09 Mar 2018 06:51:05 -0000 On Thu, Mar 8, 2018 at 8:42 PM, Bruce Evans 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