here - OSTA - Optical Storage Technology Association
here - OSTA - Optical Storage Technology Association
here - OSTA - Optical Storage Technology Association
You also want an ePaper? Increase the reach of your titles
YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.
}<br />
#ifdef (OS2 | WIN_95 | WIN_NT)<br />
/***********************************************************************<br />
* Decides if a Unicode character matches one of a list<br />
* of ASCII characters.<br />
* Used by OS2 version of IsIllegal for readability, since all of the<br />
* illegal characters above 0x0020 are in the ASCII subset of Unicode.<br />
* Works very similarly to the standard C function strchr().<br />
*<br />
* RETURN VALUE<br />
*<br />
* Non-zero if the Unicode character is in the given ASCII string.<br />
*/<br />
int UnicodeInString(<br />
unsigned char *string, /* (Input) String to search through. */<br />
unicode_t ch) /* (Input) Unicode char to search for. */<br />
{<br />
int found = FALSE;<br />
while (*string != '\0' && found == FALSE)<br />
{<br />
/* These types should compare, since both are unsigned numbers. */<br />
if (*string == ch)<br />
{<br />
found = TRUE;<br />
}<br />
string++;<br />
}<br />
return(found);<br />
}<br />
#endif /* OS2 */<br />
/***********************************************************************<br />
* Decides whether the given character is illegal for a given OS.<br />
*<br />
* RETURN VALUE<br />
*<br />
* Non-zero if char is illegal.<br />
*/<br />
int IsIllegal(unicode_t ch)<br />
{<br />
#ifdef MAC<br />
/* Only illegal character on the MAC is the colon. */<br />
if (ch == 0x003A)<br />
{<br />
return(1);<br />
}<br />
else<br />
{<br />
return(0);<br />
}<br />
#elif defined UNIX<br />
/* Illegal UNIX characters are NULL and slash. */<br />
if (ch == 0x0000 || ch == 0x002F)<br />
{<br />
return(1);<br />
}<br />
else<br />
{<br />
return(0);<br />
}<br />
#elif defined (OS2 | WIN_95 | WIN_NT)<br />
/* Illegal char's for OS/2 according to WARP toolkit. */<br />
if (ch < 0x0020 || UnicodeInString("\\/:*?\"|", ch))<br />
{<br />
return(1);<br />
}<br />
else<br />
{<br />
return(0);<br />
UDF 2.01<br />
133<br />
March50 April