mirror of
https://github.com/unicode-org/icu.git
synced 2025-04-08 06:53:45 +00:00
ICU-5319 friendly errors in data build
X-SVN-Rev: 20058
This commit is contained in:
parent
a4f5425b8b
commit
f996e8e655
2 changed files with 8 additions and 0 deletions
|
@ -466,6 +466,10 @@ addFile(const char *filename, UBool sourceTOC, UBool verbose) {
|
|||
if(!sourceTOC) {
|
||||
FileStream *file;
|
||||
|
||||
if(uprv_pathIsAbsolute(filename)) {
|
||||
fprintf(stderr, "gencmn: Error: absolute path encountered. Old style paths are not supported. Use relative paths such as 'fur.res' or 'translit%cfur.res'.\n\tBad path: '%s'\n", U_FILE_SEP_CHAR, filename);
|
||||
exit(U_ILLEGAL_ARGUMENT_ERROR);
|
||||
}
|
||||
fullPath = pathToFullPath(filename);
|
||||
|
||||
/* store the pathname */
|
||||
|
|
|
@ -585,6 +585,10 @@ static void loadLists(UPKGOptions *o, UErrorCode *status)
|
|||
|
||||
/* normal mode.. o->files is just the bare list without package names */
|
||||
o->files = pkg_appendToList(o->files, &tail, uprv_strdup(linePtr));
|
||||
if(uprv_pathIsAbsolute(s)) {
|
||||
fprintf(stderr, "pkgdata: Error: absolute path encountered. Old style paths are not supported. Use relative paths such as 'fur.res' or 'translit%cfur.res'.\n\tBad path: '%s'\n", U_FILE_SEP_CHAR, s);
|
||||
exit(U_ILLEGAL_ARGUMENT_ERROR);
|
||||
}
|
||||
uprv_strcpy(tmp, o->srcDir);
|
||||
uprv_strcat(tmp, o->srcDir[uprv_strlen(o->srcDir)-1]==U_FILE_SEP_CHAR?"":U_FILE_SEP_STRING);
|
||||
uprv_strcat(tmp, s);
|
||||
|
|
Loading…
Add table
Reference in a new issue