From patchwork Sun Sep 25 20:31:13 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dario Binacchi X-Patchwork-Id: 2385 Return-Path: X-Original-To: linux-amarula@patchwork.amarulasolutions.com Delivered-To: linux-amarula@patchwork.amarulasolutions.com Received: from mail-ej1-f72.google.com (mail-ej1-f72.google.com [209.85.218.72]) by ganimede.amarulasolutions.com (Postfix) with ESMTPS id C1ED23F030 for ; Sun, 25 Sep 2022 22:31:19 +0200 (CEST) Received: by mail-ej1-f72.google.com with SMTP id ga36-20020a1709070c2400b007837e12cd7bsf131582ejc.9 for ; Sun, 25 Sep 2022 13:31:19 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1664137879; cv=pass; d=google.com; s=arc-20160816; b=yNKm0QL8crmWTu95oROW/o2JpP/XGrIULwW3cCZFk7W5ufa4fvxs8t4boW6d7SHP3L d3LeOOyKklZTEc+oAHnlkKsAiWTr4Hc/nQwIz3N6vcdsBml0hjD1PF4kMO+7OL2dm0NR D7eoGqtbY+Y5IWMH+Zjm/GkCdsIKLhlu1wLOxMfROQMEzHuja/cXK++BMfE0XlgWp777 NPpv2NjVRm+nKhz457wxDu8oVRZMdJdaaC9r7CSbCp9cxmgRL6kjwROadyj//SOdx35+ eeoFGEEB1Z+1F+sOOm0fVsB0Mmke3Le/k6OCyxligjMSb4a6JnlBXbqVLylZ/7paaoXp B4og== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-unsubscribe:list-archive:list-help:list-post:list-id :mailing-list:precedence:mime-version:message-id:date:subject:cc:to :from:dkim-signature; bh=99bxO/2BIPueVpeEvOmFbeoRUzctgahjeQsIn9Pggjw=; b=ZT2y0+7L3/FXW8sL652n8+GaqNtRyBPRjKw4i0oSQdE1NzVVr7amRETC6ugjHy7Uti 743yNCHJQmLQi0psHHxGzf7pZ9dyfZD3YQbvTC04p+v8gvj2ibgbwu5jt4iarN0oRDOn 4eQwFokjGpnyoFN4yKzt9VgBIwNZKgXzpTUj86MPHwj7MwDflS11o8A4qQT2hyakhZ/9 U3iGMm5yETEQjsbwNAfUWqAhE/b9fcnRUgivh0rbu0LflTQJH2jfsN2EU2pTKM0RMWAs ELKic5BiQdW4PHwpO3lxPxuxvRbJtsJ1YXlvkEBCcZ65KnZ05vn8pE4ls3xPNIhYTRD2 gCEw== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@amarulasolutions.com header.s=google header.b=KAQL5uPp; spf=pass (google.com: domain of dario.binacchi@amarulasolutions.com designates 209.85.220.41 as permitted sender) smtp.mailfrom=dario.binacchi@amarulasolutions.com; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=amarulasolutions.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amarulasolutions.com; s=google; h=list-unsubscribe:list-archive:list-help:list-post:list-id :mailing-list:precedence:x-original-authentication-results :x-original-sender:mime-version:message-id:date:subject:cc:to:from :from:to:cc:subject:date; bh=99bxO/2BIPueVpeEvOmFbeoRUzctgahjeQsIn9Pggjw=; b=bGQCF53tvZ0K9aCyKt1j02QtIjag8oZ/MR9QJNk9LIamr9U75IIQ/NiPj1AtQqepzt WMec5uMWTUgRwfQIDwfzjRArruSESsTVXvmtLMzUHQgfrInobg/BeJZm0GGDYnBWI90Z ToRQ3s7sFU+eh5mOLs7paMLsT8xAfXwiAsg74= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=list-unsubscribe:list-archive:list-help:list-post :x-spam-checked-in-group:list-id:mailing-list:precedence :x-original-authentication-results:x-original-sender:mime-version :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date; bh=99bxO/2BIPueVpeEvOmFbeoRUzctgahjeQsIn9Pggjw=; b=AZ2D3BoTSU6KKrP8ORGH+p2d4ESZDu17yTLkDykCtXCiaxPrVh8xC8v384HhSQ23iN pyX0KRux2qEoHPAi/CRM2K6536VpszCE8dbnT6qYMf6VSaSHl+qastY0zQee+CXHzLZm b8r5195csaCF249FJ5JvwDfV29EtdxsVtbQhBHwH9UFeFrqdx/zkfAravKF+FBfKJwmN 9Q7yUNwY6IBCC1wYeN5OirJW4fY+kFZc3O0205jcE7950ECLpagcY0/HpT8pMW3dI0OV 8bFVWwW6l12Drtwjg81JF53CcdxCwwiwlxW/O7zP33h4g5GoThA42TyW9xi+jsX7cAoe 4ZZQ== X-Gm-Message-State: ACrzQf2pPVJifSAdtlRqh49uN7gS8pATFij4tgNfhTLP3Ur729HCKaGA B+45To2kY9Jov5HJplEK3Vl5DW8H X-Google-Smtp-Source: AMsMyM6SeobyXLEEwrc2xKYrpcohIMGoZJeo2v2H7i7b2To0oAM3Ueg7pSR87ZvaX1tVJv/nyQB9VQ== X-Received: by 2002:a05:6402:ea8:b0:456:d188:b347 with SMTP id h40-20020a0564020ea800b00456d188b347mr12649906eda.15.1664137879477; Sun, 25 Sep 2022 13:31:19 -0700 (PDT) X-BeenThere: linux-amarula@amarulasolutions.com Received: by 2002:a05:6402:34cc:b0:44e:93b9:21c8 with SMTP id w12-20020a05640234cc00b0044e93b921c8ls11951080edc.1.-pod-prod-gmail; Sun, 25 Sep 2022 13:31:18 -0700 (PDT) X-Received: by 2002:aa7:c549:0:b0:457:421d:449c with SMTP id s9-20020aa7c549000000b00457421d449cmr2649486edr.260.1664137878213; Sun, 25 Sep 2022 13:31:18 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1664137878; cv=none; d=google.com; s=arc-20160816; b=dIB5PsfgS9lo06X9unt/aM4jLEtdpZ7xqmlGccSn0HA2F5AYeepANWFxFJqq3381wT WDiACFIbLWcuANJqosMwOANNZeeL+vA6hjI7mvWUaL9xMO3rCYywY7ED4brH5WIugWbn gWgneGFiXNlAWNzfFUCKS6BAzDFQn/7ODUa0rBY7Tqt+QH+l82nqR/Bzy4Ust8/PEKRM L0I4Hs30Y2CsGXauTzv0wLNOP0GCSenCwZKa4WYclZOhxWQUdcfRbvG46l9b9+UcRNvo S/2tcHSIm6LxTaDPlzAJN89WIO3uqtOhZdlRMXmQlAEqlmMpZU1gHiyoErmhDaj8ZOwF 70ww== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:dkim-signature; bh=X8eeAPtqmw8RzZTUzvCg8gt0OKS8MUeyq5T0HoYRPyo=; b=IT5hx40BkCSIPR9qiklaBHXdgQqPkIUh5YkkdfKRoEsncwAXetsuiTv+e8yprmHi3l 3zVZrvKFDWrh2Z41+4nYfhJhqPAth9RzPkPq8fdxjA5NNdz9XJ93t1ydsotGzGYIuAyC TQ3a67FLNWzydZucm3typO/eYdxOE2jx+x9bea4avF28RTFUBv0sUOQDSx/rfRZbRaIT HVQbGv01jtFFgtK4m2sg4Tq76myolXxdHAynI5jQZ4qw/+XFygLt0LzfDOIwRlmLj06J feeHb9ZMSYJ9uylNa/e7ZsYJQ2kdjLrmeyIZcnMb7xnwCLBRm5MbmQw0tFjD6vBikuJf KpQw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@amarulasolutions.com header.s=google header.b=KAQL5uPp; spf=pass (google.com: domain of dario.binacchi@amarulasolutions.com designates 209.85.220.41 as permitted sender) smtp.mailfrom=dario.binacchi@amarulasolutions.com; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=amarulasolutions.com Received: from mail-sor-f41.google.com (mail-sor-f41.google.com. [209.85.220.41]) by mx.google.com with SMTPS id y4-20020a50ce04000000b0044dedafa4e3sor7296066edi.57.2022.09.25.13.31.18 for (Google Transport Security); Sun, 25 Sep 2022 13:31:18 -0700 (PDT) Received-SPF: pass (google.com: domain of dario.binacchi@amarulasolutions.com designates 209.85.220.41 as permitted sender) client-ip=209.85.220.41; X-Received: by 2002:aa7:d790:0:b0:457:25de:50e3 with SMTP id s16-20020aa7d790000000b0045725de50e3mr4649585edq.152.1664137877971; Sun, 25 Sep 2022 13:31:17 -0700 (PDT) Received: from dario-ThinkPad-T14s-Gen-2i.homenet.telecomitalia.it (host-95-232-92-192.retail.telecomitalia.it. [95.232.92.192]) by smtp.gmail.com with ESMTPSA id ck9-20020a0564021c0900b004575a705092sm4724edb.23.2022.09.25.13.31.16 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 25 Sep 2022 13:31:17 -0700 (PDT) From: Dario Binacchi To: busybox@busybox.net Cc: Denys Vlasenko , Erik Andersen , Rob Landley , Matt Kraai , Randolph Chung , linux-amarula@amarulasolutions.com, Dario Binacchi Subject: [RESEND RFC PATCH 1/2] fbset: abort on not handled options Date: Sun, 25 Sep 2022 22:31:13 +0200 Message-Id: <20220925203114.1537909-1-dario.binacchi@amarulasolutions.com> X-Mailer: git-send-email 2.32.0 MIME-Version: 1.0 X-Original-Sender: dario.binacchi@amarulasolutions.com X-Original-Authentication-Results: mx.google.com; dkim=pass header.i=@amarulasolutions.com header.s=google header.b=KAQL5uPp; spf=pass (google.com: domain of dario.binacchi@amarulasolutions.com designates 209.85.220.41 as permitted sender) smtp.mailfrom=dario.binacchi@amarulasolutions.com; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=amarulasolutions.com Content-Type: text/plain; charset="UTF-8" Precedence: list Mailing-list: list linux-amarula@amarulasolutions.com; contact linux-amarula+owners@amarulasolutions.com List-ID: X-Spam-Checked-In-Group: linux-amarula@amarulasolutions.com X-Google-Group-Id: 476853432473 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , Not all options are actually implemented. In this case, return a message and an error code to make it clear that the requested command has not been executed. Signed-off-by: Dario Binacchi --- util-linux/fbset.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/util-linux/fbset.c b/util-linux/fbset.c index 41cc29f37b78..0eaa7c0a6427 100644 --- a/util-linux/fbset.c +++ b/util-linux/fbset.c @@ -519,6 +519,9 @@ int fbset_main(int argc, char **argv) var_set.bits_per_pixel = xatou32(argv[1]); break; #endif + default: + bb_perror_msg_and_die("option '%s' not handled", + g_cmdoptions[i].name); } switch (g_cmdoptions[i].code) { case CMD_FB: