X-Git-Url: http://erislabs.net/gitweb/?a=blobdiff_plain;f=lib%2Funistr%2Fu16-strstr.c;h=20f94524e1b3b5e26705cf6ddfaebbf4f914a9bf;hb=d462d9f08cc8fd534ccae14c878f9c7c18112237;hp=eca5ad67682c1ed5cccb32bfd20ef124944c665e;hpb=46f74723b3fd5b41bebc0fd9c10b642726a0d47e;p=gnulib.git diff --git a/lib/unistr/u16-strstr.c b/lib/unistr/u16-strstr.c index eca5ad676..20f94524e 100644 --- a/lib/unistr/u16-strstr.c +++ b/lib/unistr/u16-strstr.c @@ -1,30 +1,37 @@ /* Substring test for UTF-16 strings. - Copyright (C) 1999, 2002, 2006 Free Software Foundation, Inc. + Copyright (C) 1999, 2002, 2006, 2010-2012 Free Software Foundation, Inc. Written by Bruno Haible , 2002. - This program is free software; you can redistribute it and/or modify it - under the terms of the GNU Library General Public License as published - by the Free Software Foundation; either version 2, or (at your option) - any later version. + This program is free software: you can redistribute it and/or modify it + under the terms of the GNU Lesser General Public License as published + by the Free Software Foundation; either version 3 of the License, or + (at your option) any later version. 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 - Library General Public License for more details. + Lesser General Public License for more details. - You should have received a copy of the GNU Library 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. */ + You should have received a copy of the GNU Lesser General Public License + along with this program. If not, see . */ #include /* Specification. */ #include "unistr.h" +#include "malloca.h" + /* FIXME: Maybe walking the string via u16_mblen is a win? */ -#define FUNC u16_strstr #define UNIT uint16_t + +#define CANON_ELEMENT(c) c +#include "str-kmp.h" + +#define FUNC u16_strstr #define U_STRCHR u16_strchr +#define U_STRMBTOUC u16_strmbtouc +#define U_STRLEN u16_strlen +#define U_STRNLEN u16_strnlen #include "u-strstr.h"