github-advanced-security[bot] commented on code in PR #1647:
URL: https://github.com/apache/mynewt-nimble/pull/1647#discussion_r1373063423


##########
nimble/transport/src/rx_task.c:
##########
@@ -0,0 +1,84 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *  http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+#include <assert.h>
+#include <syscfg/syscfg.h>
+#if MYNEWT
+#include <os/os_task.h>
+#endif
+#include <os/os_mbuf.h>
+#include <nimble/transport.h>
+#include <nimble/nimble_npl.h>
+
+#if !defined(MYNEWT) || MYNEWT_VAL(BLE_TRANSPORT_RX_STACK_SIZE) > 0
+
+static ble_transport_rx_func_t *rx_func;
+static void *rx_func_arg;
+
+#if MYNEWT
+OS_TASK_STACK_DEFINE(rx_stack, MYNEWT_VAL(BLE_TRANSPORT_RX_STACK_SIZE));
+static struct os_task rx_task;
+#endif
+
+static struct ble_npl_eventq rx_eventq;
+static struct ble_npl_event rx_event;
+
+static void
+rx_event_func(struct ble_npl_event *ev)

Review Comment:
   ## Unused static function
   
   Static function rx_event_func is unreachable
   
   [Show more 
details](https://github.com/apache/mynewt-nimble/security/code-scanning/74)



##########
nimble/transport/src/rx_task.c:
##########
@@ -0,0 +1,84 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *  http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+#include <assert.h>
+#include <syscfg/syscfg.h>
+#if MYNEWT
+#include <os/os_task.h>
+#endif
+#include <os/os_mbuf.h>
+#include <nimble/transport.h>
+#include <nimble/nimble_npl.h>
+
+#if !defined(MYNEWT) || MYNEWT_VAL(BLE_TRANSPORT_RX_STACK_SIZE) > 0
+
+static ble_transport_rx_func_t *rx_func;
+static void *rx_func_arg;
+
+#if MYNEWT
+OS_TASK_STACK_DEFINE(rx_stack, MYNEWT_VAL(BLE_TRANSPORT_RX_STACK_SIZE));
+static struct os_task rx_task;
+#endif
+
+static struct ble_npl_eventq rx_eventq;
+static struct ble_npl_event rx_event;

Review Comment:
   ## Unused static variable
   
   Static variable rx_event is never read.
   
   [Show more 
details](https://github.com/apache/mynewt-nimble/security/code-scanning/76)



##########
nimble/transport/src/rx_task.c:
##########
@@ -0,0 +1,84 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *  http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+#include <assert.h>
+#include <syscfg/syscfg.h>
+#if MYNEWT
+#include <os/os_task.h>
+#endif
+#include <os/os_mbuf.h>
+#include <nimble/transport.h>
+#include <nimble/nimble_npl.h>
+
+#if !defined(MYNEWT) || MYNEWT_VAL(BLE_TRANSPORT_RX_STACK_SIZE) > 0
+
+static ble_transport_rx_func_t *rx_func;
+static void *rx_func_arg;
+
+#if MYNEWT
+OS_TASK_STACK_DEFINE(rx_stack, MYNEWT_VAL(BLE_TRANSPORT_RX_STACK_SIZE));
+static struct os_task rx_task;
+#endif
+
+static struct ble_npl_eventq rx_eventq;
+static struct ble_npl_event rx_event;
+
+static void
+rx_event_func(struct ble_npl_event *ev)
+{
+    rx_func(rx_func_arg);
+}
+
+static void
+rx_task_func(void *arg)

Review Comment:
   ## Unused static function
   
   Static function rx_task_func is unreachable
   
   [Show more 
details](https://github.com/apache/mynewt-nimble/security/code-scanning/75)



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@mynewt.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to