From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id EFD0415800F for ; Fri, 10 Feb 2023 06:09:03 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 01BE2E07DB; Fri, 10 Feb 2023 06:09:03 +0000 (UTC) Received: from smtp.gentoo.org (woodpecker.gentoo.org [140.211.166.183]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id ADE0FE07EA for ; Fri, 10 Feb 2023 06:09:02 +0000 (UTC) Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id B2092340CCC for ; Fri, 10 Feb 2023 06:09:01 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 223FA88E for ; Fri, 10 Feb 2023 06:09:00 +0000 (UTC) From: "Sam James" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Sam James" Message-ID: <1676009250.0c9a68e0915b7c10aea37f2209579858a3d010dd.sam@gentoo> Subject: [gentoo-commits] proj/gentoo-functions:master commit in: / X-VCS-Repository: proj/gentoo-functions X-VCS-Files: functions.sh X-VCS-Directories: / X-VCS-Committer: sam X-VCS-Committer-Name: Sam James X-VCS-Revision: 0c9a68e0915b7c10aea37f2209579858a3d010dd X-VCS-Branch: master Date: Fri, 10 Feb 2023 06:09:00 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Archives-Salt: aafd95b2-6f6d-4baa-8a5e-8d130b8adf07 X-Archives-Hash: 0ffd26aedd8a0363bd91eb43b73b2e9b commit: 0c9a68e0915b7c10aea37f2209579858a3d010dd Author: Kerin Millar plushkava net> AuthorDate: Fri Feb 10 03:29:07 2023 +0000 Commit: Sam James gentoo org> CommitDate: Fri Feb 10 06:07:30 2023 +0000 URL: https://gitweb.gentoo.org/proj/gentoo-functions.git/commit/?id=0c9a68e0 Consistently specify the tag where calling esyslog() In some cases, the tag name is specified as "rc-scripts" whereas, in others, it is specified as "${0##*/}". Consistently use the latter. Eliminate some useless uses of the (non-portable) local builtin. Convey the positional parameters to esyslog() with "$@". They end up being re-joined, so they may as well be conveyed exactly as they were. Signed-off-by: Kerin Millar plushkava.net> Signed-off-by: Sam James gentoo.org> functions.sh | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/functions.sh b/functions.sh index f756a9f..9775e2c 100644 --- a/functions.sh +++ b/functions.sh @@ -127,9 +127,8 @@ ewarnn() printf " ${WARN}*${NORMAL} ${RC_INDENTATION}$*" >&2 fi - local name="${0##*/}" # Log warnings to system log - esyslog "daemon.warning" "${name}" "$*" + esyslog "daemon.warning" "${0##*/}" "$@" LAST_E_CMD="ewarnn" return 0 @@ -149,9 +148,8 @@ ewarn() printf " ${WARN}*${NORMAL} ${RC_INDENTATION}$*\n" >&2 fi - local name="${0##*/}" # Log warnings to system log - esyslog "daemon.warning" "${name}" "$*" + esyslog "daemon.warning" "${0##*/}" "$@" LAST_E_CMD="ewarn" return 0 @@ -171,9 +169,8 @@ eerrorn() printf " ${BAD}*${NORMAL} ${RC_INDENTATION}$*" >&2 fi - local name="${0##*/}" # Log errors to system log - esyslog "daemon.err" "rc-scripts" "$*" + esyslog "daemon.err" "${0##*/}" "$@" LAST_E_CMD="eerrorn" return 1 @@ -193,9 +190,8 @@ eerror() printf " ${BAD}*${NORMAL} ${RC_INDENTATION}$*\n" >&2 fi - local name="${0##*/}" # Log errors to system log - esyslog "daemon.err" "rc-scripts" "$*" + esyslog "daemon.err" "${0##*/}" "$@" LAST_E_CMD="eerror" return 1