From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 38002 invoked by alias); 4 Jul 2018 11:26:47 -0000 Mailing-List: contact libc-stable-help@sourceware.org; run by ezmlm Precedence: bulk List-Post: List-Help: List-Subscribe: List-Archive: Sender: libc-stable-owner@sourceware.org Received: (qmail 37989 invoked by uid 89); 4 Jul 2018 11:26:47 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Checked: by ClamAV 0.99.4 on sourceware.org X-Virus-Found: No X-Spam-SWARE-Status: No, score=-26.9 required=5.0 tests=BAYES_00,GIT_PATCH_0,GIT_PATCH_1,GIT_PATCH_2,GIT_PATCH_3,SPF_HELO_PASS autolearn=ham version=3.3.2 spammy= X-Spam-Status: No, score=-26.9 required=5.0 tests=BAYES_00,GIT_PATCH_0,GIT_PATCH_1,GIT_PATCH_2,GIT_PATCH_3,SPF_HELO_PASS autolearn=ham version=3.3.2 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on sourceware.org X-Spam-Level: X-HELO: mx1.redhat.com Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Wed, 04 Jul 2018 11:26:45 +0000 Received: from smtp.corp.redhat.com (int-mx11.intmail.prod.int.phx2.redhat.com [10.5.11.26]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 8F9A33002715 for ; Wed, 4 Jul 2018 11:26:44 +0000 (UTC) Received: from oldenburg.str.redhat.com (dhcp-192-212.str.redhat.com [10.33.192.212]) by smtp.corp.redhat.com (Postfix) with ESMTP id 39931300193C for ; Wed, 4 Jul 2018 11:26:44 +0000 (UTC) Received: by oldenburg.str.redhat.com (Postfix, from userid 1000) id A018543994575; Wed, 4 Jul 2018 13:26:43 +0200 (CEST) Date: Mon, 01 Jan 2018 00:00:00 -0000 To: libc-stable@sourceware.org Subject: [2.26 COMMITTED] stdio-common/tst-printf.c: Remove part under a non-free license [BZ #23363] User-Agent: Heirloom mailx 12.5 7/5/10 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Message-Id: <20180704112643.A018543994575@oldenburg.str.redhat.com> From: fweimer@redhat.com (Florian Weimer) X-Scanned-By: MIMEDefang 2.84 on 10.5.11.26 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.46]); Wed, 04 Jul 2018 11:26:44 +0000 (UTC) X-IsSubscribed: yes X-SW-Source: 2018-07/txt/msg00010.txt.bz2 The license does not allow modification. Reviewed-by: Carlos O'Donell (cherry picked from commit 5a357506659f9a00fcf5bc9c5d8fc676175c89a7) 2018-07-03 Florian Weimer [BZ #23363] * stdio-common/tst-printf.c (DEC, INT, UNS, fp_test): Remove. * stdio-common/tst-printf.sh: Adjust expected output. * LICENSES: Update. diff --git a/LICENSES b/LICENSES index 80f7f14879..858076d9d3 100644 --- a/LICENSES +++ b/LICENSES @@ -441,15 +441,6 @@ Permission to use, copy, modify, and distribute this software is freely granted, provided that this notice is preserved. -Part of stdio-common/tst-printf.c is copyright C E Chew: - -(C) Copyright C E Chew - -Feel free to copy, use and distribute this software provided: - - 1. you do not pretend that you wrote it - 2. you leave this copyright notice intact. - Various long double libm functions are copyright Stephen L. Moshier: Copyright 2001 by Stephen L. Moshier diff --git a/NEWS b/NEWS index c0b9398e83..fa6218105a 100644 --- a/NEWS +++ b/NEWS @@ -146,6 +146,7 @@ The following bugs are resolved with this release: [23236] Harden function pointers in _IO_str_fields [23313] libio: Disable vtable validation in case of interposition [23349] Various glibc headers no longer compatible with + [23363] stdio-common/tst-printf.c has non-free license Version 2.26 diff --git a/stdio-common/tst-printf.c b/stdio-common/tst-printf.c index b6d62a5a2f..9829e3ec6a 100644 --- a/stdio-common/tst-printf.c +++ b/stdio-common/tst-printf.c @@ -69,75 +69,7 @@ fmtst2chk (const char *fmt) (void) printf(fmt, 4, 4, 0x12); (void) printf("'\n"); } - -/* This page is covered by the following copyright: */ -/* (C) Copyright C E Chew - * - * Feel free to copy, use and distribute this software provided: - * - * 1. you do not pretend that you wrote it - * 2. you leave this copyright notice intact. - */ - -/* - * Extracted from exercise.c for glibc-1.05 bug report by Bruce Evans. - */ - -#define DEC -123 -#define INT 255 -#define UNS (~0) - -/* Formatted Output Test - * - * This exercises the output formatting code. - */ - -static void -fp_test (void) -{ - int i, j, k, l; - char buf[7]; - char *prefix = buf; - char tp[20]; - - puts("\nFormatted output test"); - printf("prefix 6d 6o 6x 6X 6u\n"); - strcpy(prefix, "%"); - for (i = 0; i < 2; i++) { - for (j = 0; j < 2; j++) { - for (k = 0; k < 2; k++) { - for (l = 0; l < 2; l++) { - strcpy(prefix, "%"); - if (i == 0) strcat(prefix, "-"); - if (j == 0) strcat(prefix, "+"); - if (k == 0) strcat(prefix, "#"); - if (l == 0) strcat(prefix, "0"); - printf("%5s |", prefix); - strcpy(tp, prefix); - strcat(tp, "6d |"); - printf(tp, DEC); - strcpy(tp, prefix); - strcat(tp, "6o |"); - printf(tp, INT); - strcpy(tp, prefix); - strcat(tp, "6x |"); - printf(tp, INT); - strcpy(tp, prefix); - strcat(tp, "6X |"); - printf(tp, INT); - strcpy(tp, prefix); - strcat(tp, "6u |"); - printf(tp, UNS); - printf("\n"); - } - } - } - } - printf("%10s\n", (char *) NULL); - printf("%-10s\n", (char *) NULL); -} - static int do_test (void) { @@ -235,8 +167,6 @@ I am ready for my first lesson today."; snprintf(buf2, sizeof(buf2), "%.999999u", 10)); } - fp_test (); - printf ("%e should be 1.234568e+06\n", 1234567.8); printf ("%f should be 1234567.800000\n", 1234567.8); printf ("%g should be 1.23457e+06\n", 1234567.8); diff --git a/stdio-common/tst-printf.sh b/stdio-common/tst-printf.sh index c413980dd3..5948ca2ca3 100644 --- a/stdio-common/tst-printf.sh +++ b/stdio-common/tst-printf.sh @@ -103,27 +103,6 @@ something really insane: 1.00000000000000000000000000000000000000000000000000000 | 123456.0000| 1.2346e+05| 1.235e+05| snprintf ("%30s", "foo") == 30, " " snprintf ("%.999999u", 10) == 999999 - -Formatted output test -prefix 6d 6o 6x 6X 6u -%-+#0 |-123 |0377 |0xff |0XFF |4294967295 | - %-+# |-123 |0377 |0xff |0XFF |4294967295 | - %-+0 |-123 |377 |ff |FF |4294967295 | - %-+ |-123 |377 |ff |FF |4294967295 | - %-#0 |-123 |0377 |0xff |0XFF |4294967295 | - %-# |-123 |0377 |0xff |0XFF |4294967295 | - %-0 |-123 |377 |ff |FF |4294967295 | - %- |-123 |377 |ff |FF |4294967295 | - %+#0 |-00123 |000377 |0x00ff |0X00FF |4294967295 | - %+# | -123 | 0377 | 0xff | 0XFF |4294967295 | - %+0 |-00123 |000377 |0000ff |0000FF |4294967295 | - %+ | -123 | 377 | ff | FF |4294967295 | - %#0 |-00123 |000377 |0x00ff |0X00FF |4294967295 | - %# | -123 | 0377 | 0xff | 0XFF |4294967295 | - %0 |-00123 |000377 |0000ff |0000FF |4294967295 | - % | -123 | 377 | ff | FF |4294967295 | - (null) -(null) 1.234568e+06 should be 1.234568e+06 1234567.800000 should be 1234567.800000 1.23457e+06 should be 1.23457e+06 @@ -219,27 +198,6 @@ something really insane: 1.00000000000000000000000000000000000000000000000000000 | 123456.0000| 1.2346e+05| 1.235e+05| snprintf ("%30s", "foo") == 30, " " snprintf ("%.999999u", 10) == 999999 - -Formatted output test -prefix 6d 6o 6x 6X 6u -%-+#0 |-123 |0377 |0xff |0XFF |4294967295 | - %-+# |-123 |0377 |0xff |0XFF |4294967295 | - %-+0 |-123 |377 |ff |FF |4294967295 | - %-+ |-123 |377 |ff |FF |4294967295 | - %-#0 |-123 |0377 |0xff |0XFF |4294967295 | - %-# |-123 |0377 |0xff |0XFF |4294967295 | - %-0 |-123 |377 |ff |FF |4294967295 | - %- |-123 |377 |ff |FF |4294967295 | - %+#0 |-00123 |000377 |0x00ff |0X00FF |4294967295 | - %+# | -123 | 0377 | 0xff | 0XFF |4294967295 | - %+0 |-00123 |000377 |0000ff |0000FF |4294967295 | - %+ | -123 | 377 | ff | FF |4294967295 | - %#0 |-00123 |000377 |0x00ff |0X00FF |4294967295 | - %# | -123 | 0377 | 0xff | 0XFF |4294967295 | - %0 |-00123 |000377 |0000ff |0000FF |4294967295 | - % | -123 | 377 | ff | FF |4294967295 | - (null) -(null) 1.234568e+06 should be 1.234568e+06 1234567.800000 should be 1234567.800000 1.23457e+06 should be 1.23457e+06