ICU-2487 allow alternate and file separator in tree paths

X-SVN-Rev: 15035
This commit is contained in:
Steven R. Loomis 2004-04-23 23:17:26 +00:00
parent 84dfe4bae5
commit c76c19a587

View file

@ -1133,6 +1133,16 @@ doOpenChoice(const char *path, const char *type, const char *name,
}
} else {
treeChar = uprv_strchr(path, U_TREE_SEPARATOR);
#if (U_FILE_SEP_CHAR != U_TREE_SEPARATOR)
if(treeChar == NULL) {
treeChar = uprv_strchr(path, U_FILE_SEP_CHAR);
}
#endif
#if (U_FILE_ALT_SEP_CHAR != U_TREE_SEPARATOR)
if(treeChar == NULL) {
treeChar = uprv_strchr(path, U_FILE_ALT_SEP_CHAR);
}
#endif
if(treeChar) {
TinyString_append(&treeName, treeChar+1); /* following '/' */
TinyString_appendn(&pkgName, path, treeChar-path);