From owner-freebsd-current@freebsd.org Thu Jul 9 14:14:17 2015 Return-Path: Delivered-To: freebsd-current@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 7280E996A48 for ; Thu, 9 Jul 2015 14:14:17 +0000 (UTC) (envelope-from dfr@rabson.org) Received: from mail-yk0-f173.google.com (mail-yk0-f173.google.com [209.85.160.173]) (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 3366C1B4E for ; Thu, 9 Jul 2015 14:14:16 +0000 (UTC) (envelope-from dfr@rabson.org) Received: by ykeo3 with SMTP id o3so116544201yke.0 for ; Thu, 09 Jul 2015 07:14:10 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc:content-type; bh=nr7cBEo+Ge1DDyYjSLpn4LpYlMGpmvi2i6oYZp1Gnjk=; b=c0dA+Lnn+KRvpcvxKgXEmWWwpea+JPOmXtUZoHiDIh5E7vGaBLk5IlOd+ZP+AeQajO zFiju1s8NoxZjvMUfaZL3xPilUh4rmao3P8z4A1ED2KBpBBHrqapP/ag/acmo/iBsgqS jTZFpgtuzh1atB2BLB+am5eJ3fANfZ1VqGEiURGQjPoPJqcuO9D0sePhYlcC2tyUHNAA FugDcUfxLKnCXUNUeGmPAsJMQRJpTfmjVUK7hwxoC0czUo0O9nZrKOPbEFqNU6vhZnK4 q+ilmbHlTcXb8hDvLR7dLjnoTTRXWJKqBetXp+207WrOEEtwA8RXZGkbq49m2vkjCRmF ajtg== X-Gm-Message-State: ALoCoQm291afif3paPqiTlN1etyGkYg3h1KDILH3jYKAwn1OXhQfaFnPYlNQukZJqSJtR6b6uBat MIME-Version: 1.0 X-Received: by 10.170.87.134 with SMTP id e128mr17479464yka.109.1436451249932; Thu, 09 Jul 2015 07:14:09 -0700 (PDT) Received: by 10.37.36.74 with HTTP; Thu, 9 Jul 2015 07:14:09 -0700 (PDT) In-Reply-To: <201507091404.t69E4lXJ007744@hergotha.csail.mit.edu> References: <201507072241.t67MfsX5085860@hergotha.csail.mit.edu> <94BCDA65-5B86-4329-A312-4CB16E847B69@dons.net.au> <201507081616.t68GGcY9047713@dyslexicfish.net> <0C541CE5-C322-4273-AE0B-1ACAEACCA096@gmail.com> <20150708222717.GE98562@server.rulingia.com> <20150709084145.GI2080@kib.kiev.ua> <201507091404.t69E4lXJ007744@hergotha.csail.mit.edu> Date: Thu, 9 Jul 2015 15:14:09 +0100 Message-ID: Subject: Re: gettimeofday((void *)-1, NULL) implicates core dump on recent FreeBSD 11-CURRENT From: Doug Rabson To: Garrett Wollman Cc: "oliver.pinter@hardenedbsd.org" , "freebsd-current@freebsd.org" Content-Type: text/plain; charset=UTF-8 X-Content-Filtered-By: Mailman/MimeDel 2.1.20 X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 09 Jul 2015 14:14:17 -0000 On Thursday, July 9, 2015, Garrett Wollman wrote: > In article > >, > oliver.pinter@hardenedbsd.org writes: > > >Btw, I have found this is atf's documantation: > >atf_tc_expect_signal(SIGSEGV, "reaseon"), with this, we could mark the > >specific test case could "fail" / or expect to coredump. > > No. > > I'm not sure why people are having trouble understanding this. > > The test in question is not valid C. It is entirely erroneous, and > should be deleted. Merely computing the value "(void *)-1" is allowed > to perform LITERALLY ANY ACTION AT ALL, including turning your > computer into a frog. The compiler is free to implement this as a > call to abort() if it chooses. Testing this is nonsensical. > > -GAWollman > _______________________________________________ > freebsd-current@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-current > To unsubscribe, send any mail to "freebsd-current-unsubscribe@freebsd.org > " > +1