+ pos = strstr(attr, "/*/");
+ if (pos != NULL) {
+ char str[PATH_SIZE];
+ DIR *dir;
+
+ pos[1] = '\0';
+ strlcpy(str, &pos[2], sizeof(str));
+ dir = opendir(attr);
+ if (dir != NULL) {
+ struct dirent *dent;
+
+ for (dent = readdir(dir); dent != NULL; dent = readdir(dir)) {
+ if (dent->d_name[0] == '.')
+ continue;
+ strlcat(attr, dent->d_name, sizeof(attr));
+ break;
+ }
+ closedir(dir);
+ }
+ strlcat(attr, str, sizeof(attr));
+ }
+