X-Git-Url: https://git.lttng.org/?a=blobdiff_plain;f=src%2Fcommon%2Fhashtable%2Futils.c;h=fced4570b2cc2f982eb47c2f6cb719629b357533;hb=a0377dfefe40662ba7d68617bce6ff467114136c;hp=9a84265a0b324b587470c350abd9fc989476b8d7;hpb=9a2746aaa1cddad6737cbba2bcae739cb3b84617;p=lttng-tools.git diff --git a/src/common/hashtable/utils.c b/src/common/hashtable/utils.c index 9a84265a0..fced4570b 100644 --- a/src/common/hashtable/utils.c +++ b/src/common/hashtable/utils.c @@ -1,20 +1,10 @@ /* - * Copyright (C) - Bob Jenkins, May 2006 - * Copyright (C) 2011 - David Goulet - * Copyright (C) 2011 - Mathieu Desnoyers + * Copyright (C) 2006 Bob Jenkins + * Copyright (C) 2011 David Goulet + * Copyright (C) 2011 Mathieu Desnoyers * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License, version 2 only, - * as published by the Free Software Foundation. + * SPDX-License-Identifier: GPL-2.0-only * - * This program is distributed in the hope that it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for - * more details. - * - * You should have received a copy of the GNU General Public License along - * with this program; if not, write to the Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. */ /* @@ -50,7 +40,6 @@ */ #define _LGPL_SOURCE -#include #include /* defines uint32_t etc */ #include /* defines printf for tests */ #include @@ -274,7 +263,9 @@ static void __attribute__((unused)) hashword2(const uint32_t *k, size_t length, * Use for hash table lookup, or anything where one collision in 2^^32 is * acceptable. Do NOT use for cryptographic purposes. */ -static uint32_t __attribute__((unused)) hashlittle(const void *key, +LTTNG_NO_SANITIZE_ADDRESS +__attribute__((unused)) +static uint32_t hashlittle(const void *key, size_t length, uint32_t initval) { uint32_t a,b,c;