Module Name: src
Committed By: kamil
Date: Wed Jul 25 19:09:38 UTC 2018
Modified Files:
src/sys/netbt: hci.h
Log Message:
Appease GCC in hci_filter_test()
Cast the returned value from hci_filter_test explicitly to int, as
requested by GCC when building with Undefined Behavior Sanitizer.
To generate a diff of this commit:
cvs rdiff -u -r1.44 -r1.45 src/sys/netbt/hci.h
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/sys/netbt/hci.h
diff -u src/sys/netbt/hci.h:1.44 src/sys/netbt/hci.h:1.45
--- src/sys/netbt/hci.h:1.44 Thu Dec 21 09:30:30 2017
+++ src/sys/netbt/hci.h Wed Jul 25 19:09:38 2018
@@ -1,4 +1,4 @@
-/* $NetBSD: hci.h,v 1.44 2017/12/21 09:30:30 plunky Exp $ */
+/* $NetBSD: hci.h,v 1.45 2018/07/25 19:09:38 kamil Exp $ */
/*-
* Copyright (c) 2005 Iain Hibbert.
@@ -54,7 +54,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $Id: hci.h,v 1.44 2017/12/21 09:30:30 plunky Exp $
+ * $Id: hci.h,v 1.45 2018/07/25 19:09:38 kamil Exp $
* $FreeBSD: src/sys/netgraph/bluetooth/include/ng_hci.h,v 1.6 2005/01/07 01:45:43 imp Exp $
*/
@@ -2300,7 +2300,7 @@ hci_filter_test(uint8_t bit, const struc
uint8_t off = (uint8_t)((bit - 1) >> 5);
uint8_t sh = (uint8_t)((bit - 1) & 0x1f);
- return (filter->mask[off] >> sh) & 1U;
+ return (int)((filter->mask[off] >> sh) & 1U);
}
/*