From owner-svn-src-head@freebsd.org Fri Aug 25 16:59:47 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 58195DDC944; Fri, 25 Aug 2017 16:59:47 +0000 (UTC) (envelope-from cse.cem@gmail.com) Received: from mail-oi0-f46.google.com (mail-oi0-f46.google.com [209.85.218.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 25F6E6746A; Fri, 25 Aug 2017 16:59:46 +0000 (UTC) (envelope-from cse.cem@gmail.com) Received: by mail-oi0-f46.google.com with SMTP id t88so3587713oij.0; Fri, 25 Aug 2017 09:59:46 -0700 (PDT) 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=JYFhYqx7M+lzb87tucfkmAzJ096mIIgo3MQDZuIQSAs=; b=Og4lgCSLDtHmsxu+Dfj6cK1dYekheADkm+p91/noSHkBPN+GmTznGpmeO2jG+uHsf0 OV8hc8WsS7XqJfsVoXVgOPXhMKTxD76UABOHA4NnX5JRbD2lE2eJjspCzNyGntcCpkEO oCg89+XVc6drBO6jxq1ojN/nd1GDUIbtXZ+42NYMpIPo3C766IhGk9B8D8ISkhoL+xUA 1BSgw9c5DXuiDJcaBjahafY2OI7EtDoIgdl2ZPmMEEc/xoIXKqF4Wea7cj4G/JNE8eur NlAgw6ivNb4pXrVOhwDbO34n/Rf9gjl8pltoDCDT6Fy4YvQz+hiaEoetjQQUO5yQkNa4 gItQ== X-Gm-Message-State: AHYfb5g9y2dnm05tdvGsbqSQv8DXyKQas07aX1F+RNge5f3aIZNWgzZK tiq+2q+AurdvHUN9hww= X-Received: by 10.202.212.210 with SMTP id l201mr15831348oig.180.1503680380076; Fri, 25 Aug 2017 09:59:40 -0700 (PDT) Received: from mail-io0-f172.google.com (mail-io0-f172.google.com. [209.85.223.172]) by smtp.gmail.com with ESMTPSA id n203sm6766191oia.15.2017.08.25.09.59.39 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 25 Aug 2017 09:59:39 -0700 (PDT) Received: by mail-io0-f172.google.com with SMTP id 81so1177168ioj.5; Fri, 25 Aug 2017 09:59:39 -0700 (PDT) X-Received: by 10.107.38.206 with SMTP id m197mr10094937iom.157.1503680378902; Fri, 25 Aug 2017 09:59:38 -0700 (PDT) MIME-Version: 1.0 Reply-To: cem@freebsd.org Received: by 10.2.81.131 with HTTP; Fri, 25 Aug 2017 09:59:38 -0700 (PDT) In-Reply-To: <201708251531.v7PFVtoZ038242@repo.freebsd.org> References: <201708251531.v7PFVtoZ038242@repo.freebsd.org> From: Conrad Meyer Date: Fri, 25 Aug 2017 09:59:38 -0700 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: svn commit: r322893 - head/bin/dd To: Alan Somers Cc: src-committers , svn-src-all@freebsd.org, svn-src-head@freebsd.org Content-Type: text/plain; charset="UTF-8" X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 25 Aug 2017 16:59:47 -0000 Hi Alan, By any chance did you test this change with /dev/kmem and kernel addresses ("negative" off_t values)? Thanks, Conrad On Fri, Aug 25, 2017 at 8:31 AM, Alan Somers wrote: > Author: asomers > Date: Fri Aug 25 15:31:55 2017 > New Revision: 322893 > URL: https://svnweb.freebsd.org/changeset/base/322893 > > Log: > dd(1): Incorrect casting of arguments > > dd(1) casts many of its numeric arguments from uintmax_t to intmax_t and > back again to detect whether or not the original arguments were negative. > This is not correct, and causes problems with boundary cases, for example > when count is SSIZE_MAX-1. > > PR: 191263 > Submitted by: will@worrbase.com > Reviewed by: pi, asomers > MFC after: 3 weeks