From patchwork Sun Jan 6 06:33:37 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: TAMUKI Shoichi X-Patchwork-Id: 1021039 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=sourceware.org (client-ip=209.132.180.131; helo=sourceware.org; envelope-from=libc-alpha-return-99076-incoming=patchwork.ozlabs.org@sourceware.org; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=linet.gr.jp Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; secure) header.d=sourceware.org header.i=@sourceware.org header.b="v9YiwLDs"; dkim-atps=neutral Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 43XTLv4vP8z9sCr for ; Sun, 6 Jan 2019 17:36:23 +1100 (AEDT) DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:message-id:from:date:to:subject:in-reply-to :references:mime-version:content-type; q=dns; s=default; b=mtT3G P/i4jdx6CDOIzlrIAH6+wEmghbuWrQZlEOupUS5L4z/rijT59i6LwI0LhwFhtTBO MfDjdGblfP2/xJntVzxtQSVCWt+e1z40jZNPTXr9kQY9qjc1ZO2kW+b1pim74Kwp Ih38YIO+QBBvI2osH7aTjdBJ/rg1PN2+a+kjtA= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:message-id:from:date:to:subject:in-reply-to :references:mime-version:content-type; s=default; bh=ppsuubvYMjG xJoBtBtGpMT1+/Zs=; b=v9YiwLDsEOFx3TO/oRdVlTjVL0Wywx1J8ubPCSJ3Dux Q7npf2uyg2wwJ2m5bWWQCvQgtOWIyeZFNTBLyZVAfumtsGVnHjXZ6i9LiOSkmCzD FJU7ovDeJJFK1uZ2e0AVWQl0DWrzz4hmh66MTOWJdWloW44cZG+B+v19jsrxv+zA = Received: (qmail 103254 invoked by alias); 6 Jan 2019 06:36:17 -0000 Mailing-List: contact libc-alpha-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: libc-alpha-owner@sourceware.org Delivered-To: mailing list libc-alpha@sourceware.org Received: (qmail 103236 invoked by uid 89); 6 Jan 2019 06:36:16 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-25.9 required=5.0 tests=BAYES_00, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, KAM_LAZY_DOMAIN_SECURITY, RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.2 spammy=2122, H*UA:Version X-HELO: mail.linet.jp Message-Id: <201901060633.AA04157@tamuki.linet.gr.jp> From: TAMUKI Shoichi Date: Sun, 06 Jan 2019 15:33:37 +0900 To: libc-alpha@sourceware.org Subject: [PATCH v5 1/5] strftime: Add missing uses of L_ macro, etc. [BZ #23758] In-Reply-To: <201901060628.AA04156@tamuki.linet.gr.jp> References: <201901060628.AA04156@tamuki.linet.gr.jp> MIME-Version: 1.0 At first, make an unrelated changes for the consistency. ChangeLog: [BZ #23758] * time/strftime_l.c (__strftime_internal): Add missing uses of L_ macro, also add a missing space after the cast of _NL_CURRENT. --- time/strftime_l.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/time/strftime_l.c b/time/strftime_l.c index 6919749c630..7ba4179de3e 100644 --- a/time/strftime_l.c +++ b/time/strftime_l.c @@ -820,7 +820,7 @@ __strftime_internal (CHAR_T *s, size_t maxsize, const CHAR_T *format, if (modifier == L_('O')) goto bad_format; #ifdef _NL_CURRENT - if (! (modifier == 'E' + if (! (modifier == L_('E') && (*(subfmt = (const CHAR_T *) _NL_CURRENT (LC_TIME, NLW(ERA_D_T_FMT))) @@ -917,7 +917,7 @@ __strftime_internal (CHAR_T *s, size_t maxsize, const CHAR_T *format, #ifdef _NL_CURRENT if (! (modifier == L_('E') && (*(subfmt = - (const CHAR_T *)_NL_CURRENT (LC_TIME, NLW(ERA_D_FMT))) + (const CHAR_T *) _NL_CURRENT (LC_TIME, NLW(ERA_D_FMT))) != L_('\0')))) subfmt = (const CHAR_T *) _NL_CURRENT (LC_TIME, NLW(D_FMT)); goto subformat; @@ -1262,7 +1262,7 @@ __strftime_internal (CHAR_T *s, size_t maxsize, const CHAR_T *format, DO_NUMBER (1, tp->tm_wday); case L_('Y'): - if (modifier == 'E') + if (modifier == L_('E')) { #if HAVE_STRUCT_ERA_ENTRY struct era_entry *era = _nl_get_era_entry (tp HELPER_LOCALE_ARG);