Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp17996677rwd; Tue, 27 Jun 2023 10:06:58 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ4pE3QUMCZyLqacq5D8voLhxH7XZVLqP2CywHDFlU/1YL1xVVCjygrGeT7eGP72QgseYDq8 X-Received: by 2002:a17:907:9449:b0:988:6491:98e1 with SMTP id dl9-20020a170907944900b00988649198e1mr22196027ejc.42.1687885617917; Tue, 27 Jun 2023 10:06:57 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1687885617; cv=none; d=google.com; s=arc-20160816; b=JuUMlS5zaOsFuZTHH3UTGoKUuQzmj+sF2A1H6/XNG7FRutj5WvocO+OKcP0qi5lrwx 2EkzdIp0jAP7rEb4+vz4y/X8eJ3uprtYUjWucCFa1Dj8lzTey9WPG2ZekHdZq5L7eryu E/Bjy3EgTv2vKjdTTJ1oUZsgXx9axKUVW5ijnnQkCUOdyFpjPFqKhFg5vutElH/ZwICk xDAl+IguG0wzXB1nt0TwaTzozwQzFiAjyA+0SrRXZg8wg6uVmjjFB2Zu0dUE8JJY2TBP nOQexEz3nEqqN53uAjPr8xTm2B/q8dn1pX7sTeCU1sX/VWDfIygPQ7qRTAOZqK1kHseJ Ixzw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version:subject :message-id:to:from:date:dkim-signature; bh=9t7pAo7w8VWRQq5MpllqEBIUk0Vw+t7yXifhpsUKCII=; fh=4lGQI6056MBa4/oovMyIYaKLn+Wz/24RGvUivMmQP8E=; b=ireSUeQQjMcVryKfTJ5t5FlsQuCWP8eN4fDbAk1wTVMTblz1art4cDO0xzPOLRHcGE YEgTKIN2Ul1yDCjd+yHXE0ssZBBgeEkZL2zbTqOEz4mUbCUwaUfBbk/h0p7TIXC6MAUj g9jtUUHM/u2JHVBe2r4zr/6B2bRSDhP7goSk71lGlPBpGHilRl7Nr8unbuQcCJmF0MY2 sD//HvJLL4lwKSG+Y20EQOu/ClYp8/5BUYuAAOPSa3yexWYwBMHGYCbF0cy2GgA0jEeV TS6DgXqOMx9whqjeeOutIDkBT3VIMOZlm8JwdxPCQce+LzkMf0eYmxip9035cYWtPZku 0q0w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@github.com header.s=pf2023 header.b=hcQISaVt; spf=pass (google.com: domain of linux-bluetooth-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-bluetooth-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=github.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id g20-20020a170906349400b009591dd6c71esi4362200ejb.896.2023.06.27.10.05.56; Tue, 27 Jun 2023 10:06:57 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-bluetooth-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@github.com header.s=pf2023 header.b=hcQISaVt; spf=pass (google.com: domain of linux-bluetooth-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-bluetooth-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=github.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231760AbjF0Qla (ORCPT + 99 others); Tue, 27 Jun 2023 12:41:30 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58882 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231727AbjF0QlZ (ORCPT ); Tue, 27 Jun 2023 12:41:25 -0400 Received: from out-26.smtp.github.com (out-26.smtp.github.com [192.30.252.209]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B3DECE52 for ; Tue, 27 Jun 2023 09:41:11 -0700 (PDT) Received: from github.com (hubbernetes-node-a3635c1.ash1-iad.github.net [10.56.202.78]) by smtp.github.com (Postfix) with ESMTPA id ECBF2600090 for ; Tue, 27 Jun 2023 09:41:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=github.com; s=pf2023; t=1687884070; bh=9t7pAo7w8VWRQq5MpllqEBIUk0Vw+t7yXifhpsUKCII=; h=Date:From:To:Subject:From; b=hcQISaVtHgbUVD1EToLPswxcOXOXw1Aeu4lDD+oTpD0QrWP1hg07lu8DVnvR/JZPR pn6/kLQ8ELj3KlyAK7KEwGhjDc2TamItAapZm+Av3aGvDqSjHIBgSCs19Sa/Qv57Kd eYqFdstj/RGu+XAJfhTQuGVxajJr79XO7+guZ9DE= Date: Tue, 27 Jun 2023 09:41:10 -0700 From: Marcel Holtmann To: linux-bluetooth@vger.kernel.org Message-ID: Subject: [bluez/bluez] 6b9d16: android: Fix compiler warning from GCC Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-GitHub-Recipient-Address: linux-bluetooth@vger.kernel.org X-Auto-Response-Suppress: All X-Spam-Status: No, score=-2.8 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_LOW, RCVD_IN_MSPIKE_H4,RCVD_IN_MSPIKE_WL,SPF_HELO_NONE,SPF_NONE, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-bluetooth@vger.kernel.org Branch: refs/heads/master Home: https://github.com/bluez/bluez Commit: 6b9d167034b741605c3186e78e9742dda8e28e08 https://github.com/bluez/bluez/commit/6b9d167034b741605c3186e78e974= 2dda8e28e08 Author: Marcel Holtmann Date: 2023-06-27 (Tue, 27 Jun 2023) Changed paths: M android/gatt.c Log Message: ----------- android: Fix compiler warning from GCC This ignores the following two warnings from the compiler. CC android/gatt.o android/gatt.c: In function =E2=80=98handle_client_register_for_notificat= ion=E2=80=99: android/gatt.c:3733:9: error: =E2=80=98memcpy=E2=80=99 offset [0, 16] is = out of the bounds [0, 0] [-Werror=3Darray-bounds=3D] 3733 | memcpy(¬ification->ch, &cmd->char_id, sizeof(notificat= ion->ch)); | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~= ~~~~~~~~~ CC android/gatt.o android/gatt.c: In function =E2=80=98handle_client_register_for_notificat= ion=E2=80=99: android/gatt.c:3735:9: error: =E2=80=98memcpy=E2=80=99 writing 17 bytes i= nto a region of size 0 overflows the destination [-Werror=3Dstringop-over= flow=3D] 3735 | memcpy(¬ification->ch, &cmd->char_id, sizeof(notificat= ion->ch)); | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~= ~~~~~~~~~ It could be possible that these warnings are valid or they might be a false positive. However since this is Android based code based on Android HAL headers, just set pragma to ignore them.