Bug fix to string comparison functions.

Added UTF-8 test and coercion functions.

Use UTF-8 test and coercion functions to handle Latin-1 text in AVU
attributes.
Use strnlen in preference to strlen.