g_utf8_validate: @str shouldn't end up annotated as utf8

In order for this function to have any point, it has to be possible to
pass non-UTF-8 data to it, so annotate @str as being array-of-guint8
instead of utf8.

https://bugzilla.gnome.org/show_bug.cgi?id=672548
This commit is contained in:
Dan Winship 2012-03-21 09:22:38 -04:00
parent 8df2b96a69
commit 7cadf4f15f

View File

@ -1595,7 +1595,7 @@ fast_validate_len (const char *str,
/**
* g_utf8_validate:
* @str: a pointer to character data
* @str: (array length=max_len) (element-type guint8): a pointer to character data
* @max_len: max bytes to validate, or -1 to go until NUL
* @end: (allow-none) (out): return location for end of valid data
*