here - OSTA - Optical Storage Technology Association
here - OSTA - Optical Storage Technology Association
here - OSTA - Optical Storage Technology Association
Create successful ePaper yourself
Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.
nameLen = udfNameLen;<br />
}<br />
else {<br />
/* A DOS extension was found, process it first. */<br />
extLen = udfNameLen - index - 1;<br />
nameLen = index;<br />
targetIndex = 0;<br />
bytesLeft = DOS_EXT_LEN;<br />
while (++index < udfNameLen && bytesLeft > 0) {<br />
/* Get the current character and convert it to upper */<br />
/* case. */<br />
current = UnicodeToUpper(udfName[index]);<br />
if (current == ' ') {<br />
/* If a space is found, a CRC must be appended to */<br />
/* the mangled file name. */<br />
needsCRC = TRUE;<br />
}<br />
else {<br />
/* Determine if this is a valid file name char and */<br />
/* calculate its corresponding BCS character byte */<br />
/* length (zero if the char is not legal or */<br />
/* undisplayable on this system). */<br />
charLen = (IsFileNameCharLegal(current)) ?<br />
NativeCharLength(current) : 0;<br />
/* If the char is larger than the available space */<br />
/* in the buffer, pretend it is undisplayable. */<br />
if (charLen > bytesLeft)<br />
charLen = 0;<br />
if (charLen == 0) {<br />
/* Undisplayable or illegal characters are */<br />
/* substituted with an underscore ("_"), and */<br />
/* required a CRC code appended to the mangled */<br />
/* file name. */<br />
needsCRC = TRUE;<br />
charLen = 1;<br />
current = '_';<br />
}<br />
}<br />
/* Skip over any following undiplayable or */<br />
/* illegal chars. */<br />
while (index +1 0) {<br />
/* Get the current character and convert it to upper case. */<br />
current = UnicodeToUpper(udfName[index]);<br />
if (current ==' ' ||current == '.') {<br />
/* Spaces and periods are just skipped, a CRC code */<br />
/* must be added to the mangled file name. */<br />
needsCRC = TRUE;<br />
}<br />
else {<br />
UDF 2.01<br />
123<br />
March50 April