Replace more unallowed characters
authorMarcel Holtmann <marcel@holtmann.org>
Wed, 3 Dec 2008 13:59:14 +0000 (14:59 +0100)
committerMarcel Holtmann <marcel@holtmann.org>
Wed, 3 Dec 2008 13:59:14 +0000 (14:59 +0100)
plugins/wifi.c

index 6793eb4..5104586 100644 (file)
@@ -185,7 +185,11 @@ static void scan_result(struct connman_element *parent,
        temp = g_strdup(network->identifier);
 
        for (i = 0; i < strlen(temp); i++) {
-               if (temp[i] == ' ' || temp[i] == '.' || temp[i] == '-')
+               if (temp[i] == ' ' || temp[i] == '.')
+                       temp[i] = '_';
+               else if (temp[i] == '-' || temp[i] == '+')
+                       temp[i] = '_';
+               else if (temp[i] == '!' || temp[i] == '?')
                        temp[i] = '_';
                else if (temp[i] == '(' || temp[i] == ')')
                        temp[i] = '_';