Diff for /np2/generic/hostdrvs.c between versions 1.6 and 1.9

version 1.6, 2004/01/12 08:51:24 version 1.9, 2004/06/20 02:57:47
Line 1 Line 1
 #include        "compiler.h"  #include        "compiler.h"
   
   #if defined(SUPPORT_HOSTDRV)
   
 #if defined(OSLANG_EUC)  #if defined(OSLANG_EUC)
 #include        "codecnv.h"  #include        "codecnv.h"
 #endif  #endif
Line 8 Line 11
 #include        "hostdrvs.h"  #include        "hostdrvs.h"
   
   
 static const HDRVDIR hddroot = {"           ", 0, 0, 0x10, {0}, {0}};  static const HDRVDIR hddroot = {"           ", 0, 0, 0, 0x10, {0}, {0}};
   
 static const BYTE dospathchr[] = {  static const BYTE dospathchr[] = {
                         0xfa, 0x23,             // '&%$#"!  /.-,+*)(                          0xfa, 0x23,             // '&%$#"!  /.-,+*)(
Line 28  static void rcnvfcb(char *dst, UINT dlen Line 31  static void rcnvfcb(char *dst, UINT dlen
                 if (c == 0) {                  if (c == 0) {
                         break;                          break;
                 }                  }
 #if defined(OSLANG_SJIS) || defined(OSLANG_EUC)  #if defined(OSLANG_SJIS) || defined(OSLANG_EUC) || defined(OSLANG_UTF8)
                 if ((((c ^ 0x20) - 0xa1) & 0xff) < 0x3c) {                  if ((((c ^ 0x20) - 0xa1) & 0xff) < 0x3c) {
                         if ((!slen) || (src[0] == '\0')) {                          if ((!slen) || (src[0] == '\0')) {
                                 break;                                  break;
Line 74  static void rcnvfcb(char *dst, UINT dlen Line 77  static void rcnvfcb(char *dst, UINT dlen
   
 static BOOL realname2fcb(char *fcbname, FLINFO *fli) {  static BOOL realname2fcb(char *fcbname, FLINFO *fli) {
   
   #if defined(OSLANG_EUC) || defined(OSLANG_UTF8)
           char    sjis[MAX_PATH];
   #endif
         char    *realname;          char    *realname;
         char    *ext;          char    *ext;
   
 #if defined(OSLANG_EUC)  #if defined(OSLANG_EUC)
         char            sjis[MAX_PATH];  
   
         codecnv_euc2sjis(sjis, sizeof(sjis), fli->path, sizeof(fli->path));          codecnv_euc2sjis(sjis, sizeof(sjis), fli->path, sizeof(fli->path));
         realname = sjis;          realname = sjis;
   #elif defined(OSLANG_UTF8)
           oemtext_oem2sjis(sjis, sizeof(sjis), fli->path, sizeof(fli->path));
           realname = sjis;
 #else  #else
         realname = fli->path;          realname = fli->path;
 #endif  #endif
         FillMemory(fcbname, 11, ' ');          FillMemory(fcbname, 11, ' ');
           // ToDo: SJISに変換済みなのに OEM依存してる
         ext = file_getext(realname);          ext = file_getext(realname);
         rcnvfcb(fcbname+0, 8, realname, ext - realname);          rcnvfcb(fcbname+0, 8, realname, ext - realname);
         rcnvfcb(fcbname+8, 3, ext, (UINT)-1);          rcnvfcb(fcbname+8, 3, ext, (UINT)-1);
Line 134  LISTARRAY hostdrvs_getpathlist(const cha Line 142  LISTARRAY hostdrvs_getpathlist(const cha
                                 break;                                  break;
                         }                          }
                         CopyMemory(hdd->di.fcbname, fcbname, 11);                          CopyMemory(hdd->di.fcbname, fcbname, 11);
                           hdd->di.exist = 1;
                         hdd->di.caps = fli.caps;                          hdd->di.caps = fli.caps;
                         hdd->di.size = fli.size;                          hdd->di.size = fli.size;
                         hdd->di.attr = fli.attr;                          hdd->di.attr = fli.attr;
Line 334  BOOL hostdrvs_newrealpath(HDRVPATH *hdp, Line 343  BOOL hostdrvs_newrealpath(HDRVPATH *hdp,
   
 // ----  // ----
   
 void hostdrvs_fhdlreopen(LISTARRAY fhdl) {  
   
         (void)fhdl;  
 }  
   
 static BOOL fhdlallclose(void *vpItem, void *vpArg) {  static BOOL fhdlallclose(void *vpItem, void *vpArg) {
   
         long    fh;          long    fh;
Line 383  HDRVFILE hostdrvs_fhdlsea(LISTARRAY fhdl Line 387  HDRVFILE hostdrvs_fhdlsea(LISTARRAY fhdl
         return(ret);          return(ret);
 }  }
   
   #endif
   

Removed from v.1.6  
changed lines
  Added in v.1.9


RetroPC.NET-CVS <cvs@retropc.net>