allow most UTF-8 characters in options

This commit is contained in:
IgnorantGuru 2012-08-19 09:35:15 -06:00
parent 8f018e1e3e
commit 1098494819
2 changed files with 6 additions and 5 deletions

View File

@ -1,5 +1,7 @@
0.3.2+
update ru.po
no quote cifs password
allow most UTF-8 characters in options
0.3.2 2012-08-15:
accept smb workgroup/user
curlftpfs pass user:pass as option

View File

@ -3474,12 +3474,11 @@ _get_type:
}
// test options
if ( ( i = strspn( options,
"abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789-=+_,.:;\"'$@/" ) )
!= strlen( options ) )
if ( ( str2 = g_utf8_strchr( options, -1, '\\' ) ) ||
( str2 = g_utf8_strchr( options, -1, ' ' ) ) )
{
str = g_strdup_printf( _("udevil: error 89: options contain an invalid character ('%c')\n"),
options[i] );
str2[0] );
wlog( str, NULL, 2 );
g_free( str );
ret = 1;