From patchwork Fri Sep 25 06:37:02 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Alexandru Ardelean X-Patchwork-Id: 522653 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from arrakis.dune.hu (arrakis.dune.hu [78.24.191.176]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 097581401F6 for ; Fri, 25 Sep 2015 16:37:28 +1000 (AEST) Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b=u8sB56A7; dkim-atps=neutral Received: from arrakis.dune.hu (localhost [127.0.0.1]) by arrakis.dune.hu (Postfix) with ESMTP id 0EEB128BCD0; Fri, 25 Sep 2015 08:36:02 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on arrakis.dune.hu X-Spam-Level: X-Spam-Status: No, score=-1.5 required=5.0 tests=BAYES_00,FREEMAIL_FROM, T_DKIM_INVALID autolearn=unavailable version=3.3.2 Received: from arrakis.dune.hu (localhost [127.0.0.1]) by arrakis.dune.hu (Postfix) with ESMTP id 6972928BCAA for ; Fri, 25 Sep 2015 08:35:53 +0200 (CEST) X-policyd-weight: using cached result; rate: -8.5 Received: from mail-wi0-f179.google.com (mail-wi0-f179.google.com [209.85.212.179]) by arrakis.dune.hu (Postfix) with ESMTPS for ; Fri, 25 Sep 2015 08:35:52 +0200 (CEST) Received: by wicge5 with SMTP id ge5so6616717wic.0 for ; Thu, 24 Sep 2015 23:37:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id; bh=1xfXIn1SCMtGqXN/SIDLx3nH7etMpQ13kU+AivNchjs=; b=u8sB56A7MdXj4mVXR9Oge2RGk77+eF2e8tlWAJJsAgwlW8APfDXM8jyLy/5lb3/zJy rODboAxne2Qxd4XZ5tUvp4iGrVJfFPOFyega+0SyydGM08YhqG6LWNZLWAKycPA25QyQ JUOOp2gqoWySeZ38TJwd3Uxjq7ukBwtnXSOEdGpAcbzxr1K0jWz15a0mYa59kzWlSYMo y6tRvKaPNmizB+yQrz9ktrxHg93A1UI6vKYPtwZhPbNBcEWl7JDJ00C2iHJ6pE9vCcNY R+SK/K1OQlBzKw9T5gLCJi/c3mfLI1Oku7OhSMoagkKbLlwmO+2q581JD7mDML+D3mgk L2Qg== X-Received: by 10.194.237.232 with SMTP id vf8mr4119033wjc.22.1443163029329; Thu, 24 Sep 2015 23:37:09 -0700 (PDT) Received: from orion.ocedo.cluj.local ([5.2.198.78]) by smtp.gmail.com with ESMTPSA id fz1sm1648561wic.8.2015.09.24.23.37.08 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 24 Sep 2015 23:37:08 -0700 (PDT) From: Alexandru Ardelean To: openwrt-devel@lists.openwrt.org Date: Fri, 25 Sep 2015 09:37:02 +0300 Message-Id: <1443163022-9028-1-git-send-email-ardeleanalex@gmail.com> X-Mailer: git-send-email 2.1.4 Cc: Alexandru Ardelean Subject: [OpenWrt-Devel] [PATCH] lldpd: wrap procd command args in separate quotes X-BeenThere: openwrt-devel@lists.openwrt.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: OpenWrt Development List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: openwrt-devel-bounces@lists.openwrt.org Sender: "openwrt-devel" From: Alexandru Ardelean Seems the match pattern was being adapted from 'eth0' to ' eth0' because of the way I added the procd command args. This did not seem to be a problem when there were multiple interfaces, just on devices with single interfaces for lldpd to listen on. Signed-off-by: Alexandru Ardelean --- package/network/services/lldpd/files/lldpd.init | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/package/network/services/lldpd/files/lldpd.init b/package/network/services/lldpd/files/lldpd.init index 278dbaf..3d7d8b9 100644 --- a/package/network/services/lldpd/files/lldpd.init +++ b/package/network/services/lldpd/files/lldpd.init @@ -54,14 +54,14 @@ start_service() { procd_set_param command /usr/sbin/lldpd procd_append_param command -d # don't daemonize, procd will handle that for us - [ -n "$ifnames" ] && procd_append_param command "-I $ifnames" + [ -n "$ifnames" ] && procd_append_param command -I "$ifnames" [ $enable_cdp -gt 0 ] && procd_append_param command '-c' [ $enable_fdp -gt 0 ] && procd_append_param command '-f' [ $enable_sonmp -gt 0 ] && procd_append_param command '-s' [ $enable_edp -gt 0 ] && procd_append_param command '-e' [ $readonly_mode -gt 0 ] && procd_append_param command '-r' - [ -n "$lldp_class" ] && procd_append_param command "-M $lldp_class" - [ -n "$lldp_description" ] && procd_append_param command "-S $lldp_description" + [ -n "$lldp_class" ] && procd_append_param command -M "$lldp_class" + [ -n "$lldp_description" ] && procd_append_param command -S "$lldp_description" # set auto respawn behavior procd_set_param respawn