Use strstr instead of g_strstr with -1 for length.

* gtk/gtkentrycompletion.c (gtk_entry_completion_insert_completion_text): 
	Use strstr instead of g_strstr with -1 for length.

svn path=/trunk/; revision=17668
This commit is contained in:
Xan Lopez 2007-04-28 11:28:58 +00:00
parent 446014dfb8
commit a5c702e545
2 changed files with 6 additions and 1 deletions

View File

@ -1,3 +1,8 @@
2007-04-28 Xan Lopez <xan@gnome.org>
* gtk/gtkentrycompletion.c (gtk_entry_completion_insert_completion_text):
Use strstr instead of g_strstr with -1 for length.
2007-04-28 Xan Lopez <xan@gnome.org>
* gtk/gtkentry.c:

View File

@ -1677,7 +1677,7 @@ gtk_entry_completion_insert_completion_text (GtkEntryCompletion *completion,
}
gtk_entry_set_text (GTK_ENTRY (priv->entry), text);
needle = g_strstr_len (text, -1, completion->priv->completion_prefix);
needle = strstr (text, completion->priv->completion_prefix);
if (needle)
{
len = g_utf8_strlen (text, -1) - g_utf8_strlen (needle, -1)