From owner-svn-src-head@freebsd.org Thu Aug 3 11:49:13 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 8A4F8DB2E1E for ; Thu, 3 Aug 2017 11:49:13 +0000 (UTC) (envelope-from ed@nuxi.nl) Received: from mail-yw0-x232.google.com (mail-yw0-x232.google.com [IPv6:2607:f8b0:4002:c05::232]) (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 4E5CE73D75 for ; Thu, 3 Aug 2017 11:49:12 +0000 (UTC) (envelope-from ed@nuxi.nl) Received: by mail-yw0-x232.google.com with SMTP id l82so6652662ywc.2 for ; Thu, 03 Aug 2017 04:49:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nuxi-nl.20150623.gappssmtp.com; s=20150623; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=aOyJ+/Xe93y+3+PpIBZv+iBe4n9nStyjkLkGNLTMHNA=; b=M95h/LqZDOj02WcXaZ/4t97N8uOcp5K9coRx9P1VNej3q1qyf4BVR7rxRG39kLKwuf bIsV7l6581MYK+5+sNJTFiWGwroB8S5z5tA/2Mo3dLQnGYqwlhmvtNgrrqCc9Jy8RYP4 mONbbFF9i5IkvSXE3m+lSb8DplZVydQ34iiUtft21iOmv4J+oj2CWtfM8XrkkcZ0OIiq 5Vy1x0ltm08VTUp6VVm1rhWqeqjrA4OsCWYIuKgu4j7oMLLRDLWSrXFI7yhlbRRe64Ma lSs9NPO2GoYLU6yYzuAtjX7E1RvRMOBX5ipzC9GFkrsTBitHHiSBQLganghHK7UAJRwJ EM0g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=aOyJ+/Xe93y+3+PpIBZv+iBe4n9nStyjkLkGNLTMHNA=; b=X40JjWKtWbdBXWcyh5XRAMICo4RmKhNmcyBsyOk/m0x5yiRNqDVP3Tf9NiAsrBGTxX zRtLHz0nDNgraMmJvOCsrcgCX267kdzitJW3mT+aXRV76m40JhcOr7Ru6S3vBNaldoTt PnsPyXx5CbCYV66r4PTFnYqvAtLEjz3VmntatxIuPA3Ka871tFwIVxueIhDUE2tTUAuY ep4pyiIuSJth4f73zs+hOk05kYVbWFUidJyvM9wXiVaBcIbpc25/V84X80oBGM7kO9hS GVFcx3RKZA+pUZ/gDqk/fs7TBLGZkm9rlfmijeWIzJaBLqe3VV7+f2wMWteu2UnGtb/8 1cjA== X-Gm-Message-State: AIVw113RLCFX5zgCh6TtmNF0ha3jTGy9U7mRHQDIRJHKb5+c+Bc4++3e b1KEWzvIZW3N53nrYHc9BPzIs4rUQcc6 X-Received: by 10.129.226.5 with SMTP id p5mr947560ywl.0.1501760951987; Thu, 03 Aug 2017 04:49:11 -0700 (PDT) MIME-Version: 1.0 Received: by 10.13.218.69 with HTTP; Thu, 3 Aug 2017 04:48:41 -0700 (PDT) In-Reply-To: <201708030527.v735R5dg041043@repo.freebsd.org> References: <201708030527.v735R5dg041043@repo.freebsd.org> From: Ed Schouten Date: Thu, 3 Aug 2017 13:48:41 +0200 Message-ID: Subject: Re: svn commit: r321969 - in head/sys/boot: arm/at91/libat91 arm/ixp425/boot2 i386/boot2 To: Ngie Cooper 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: Thu, 03 Aug 2017 11:49:13 -0000 2017-08-03 7:27 GMT+02:00 Ngie Cooper : > Modified: head/sys/boot/arm/at91/libat91/printf.c > ============================================================================== > --- head/sys/boot/arm/at91/libat91/printf.c Thu Aug 3 03:45:48 2017 (r321968) > +++ head/sys/boot/arm/at91/libat91/printf.c Thu Aug 3 05:27:05 2017 (r321969) > @@ -20,12 +20,13 @@ > #include > #include "lib.h" > > -void > +int > printf(const char *fmt,...) > { > va_list ap; > const char *hex = "0123456789abcdef"; > char buf[10]; > + const char *fmt_orig = fmt; > char *s; > unsigned u; > int c; > @@ -66,5 +67,5 @@ printf(const char *fmt,...) > } > va_end(ap); > > - return; > + return (int)(fmt - fmt_orig); > } This makes printf() return the number of characters from the format processed, right? This is different from libc's printf(), which returns the number of characters printed. -- Ed Schouten Nuxi, 's-Hertogenbosch, the Netherlands KvK-nr.: 62051717