From nobody@FreeBSD.org  Fri Oct 12 14:18:18 2012
Return-Path: <nobody@FreeBSD.org>
Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52])
	by hub.freebsd.org (Postfix) with ESMTP id 2398FB4B
	for <freebsd-gnats-submit@FreeBSD.org>; Fri, 12 Oct 2012 14:18:18 +0000 (UTC)
	(envelope-from nobody@FreeBSD.org)
Received: from red.freebsd.org (red.freebsd.org [IPv6:2001:4f8:fff6::22])
	by mx1.freebsd.org (Postfix) with ESMTP id 0D6708FC08
	for <freebsd-gnats-submit@FreeBSD.org>; Fri, 12 Oct 2012 14:18:18 +0000 (UTC)
Received: from red.freebsd.org (localhost [127.0.0.1])
	by red.freebsd.org (8.14.5/8.14.5) with ESMTP id q9CEIHLq092612
	for <freebsd-gnats-submit@FreeBSD.org>; Fri, 12 Oct 2012 14:18:17 GMT
	(envelope-from nobody@red.freebsd.org)
Received: (from nobody@localhost)
	by red.freebsd.org (8.14.5/8.14.5/Submit) id q9CEIHK7092611;
	Fri, 12 Oct 2012 14:18:17 GMT
	(envelope-from nobody)
Message-Id: <201210121418.q9CEIHK7092611@red.freebsd.org>
Date: Fri, 12 Oct 2012 14:18:17 GMT
From: Erik Cederstrand <erik@cederstrand.dk>
To: freebsd-gnats-submit@FreeBSD.org
Subject: usr.bin/awk: mark FATAL() as __noreturn__
X-Send-Pr-Version: www-3.1
X-GNATS-Notify:

>Number:         172639
>Category:       bin
>Synopsis:       usr.bin/awk: mark FATAL() as __noreturn__
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    eadler
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Fri Oct 12 14:20:00 UTC 2012
>Closed-Date:    Fri Nov 09 01:36:47 UTC 2012
>Last-Modified:  Fri Nov 09 01:36:47 UTC 2012
>Originator:     Erik Cederstrand
>Release:        CURRENT
>Organization:
>Environment:
>Description:
This is similar to misc/172636. awk has a function FATAL() that unconditionally calls exit(). Mark it as such in the header prototype.
>How-To-Repeat:

>Fix:
See patch

Patch attached with submission follows:

Index: head/contrib/one-true-awk/proto.h
===================================================================
--- head/contrib/one-true-awk/proto.h	(revision 241481)
+++ head/contrib/one-true-awk/proto.h	(working copy)
@@ -132,7 +132,7 @@
 extern	void	bracecheck(void);
 extern	void	bcheck2(int, int, int);
 extern	void	SYNTAX(const char *, ...);
-extern	void	FATAL(const char *, ...);
+extern	void	FATAL(const char *, ...) __attribute__ ((__noreturn__));
 extern	void	WARNING(const char *, ...);
 extern	void	error(void);
 extern	void	eprint(void);


>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: freebsd-bugs->eadler 
Responsible-Changed-By: eadler 
Responsible-Changed-When: Fri Oct 12 14:30:18 UTC 2012 
Responsible-Changed-Why:  
I'll take it. FWIW, we generally don't patch contributed software 
(anything in crypto/ or contrib/) but I'll take a look at this one. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=172639 
State-Changed-From-To: open->closed 
State-Changed-By: eadler 
State-Changed-When: Fri Nov 9 01:36:47 UTC 2012 
State-Changed-Why:  
I opted to not fix this internally as it is a low-pri issue and a 
contributed piece of software. Perhaps this should be sent upstream? 

http://www.freebsd.org/cgi/query-pr.cgi?pr=172639 
>Unformatted:
