Chameleon

Chameleon Commit Details

Date:2014-11-29 15:42:22 (9 years 4 months ago)
Author:ErmaC
Commit:2499
Parents: 2498
Message:typo
Changes:
M/branches/ErmaC/Enoch/i386/libsaio/msdos.c
M/branches/ErmaC/Enoch/i386/libsaio/platform.h

File differences

branches/ErmaC/Enoch/i386/libsaio/platform.h
360360
361361
362362
363
363
364364
365365
366366
uint32_tMinRatio;// Min Bus Ratio
uint32_tCPUID[CPUID_MAX][4];// CPUID 0..4, 80..81 Raw Values
uint32_tMCodeVersion; // CPU Microcode version
uint32_tMCodeVersion;// CPU Microcode version
} CPU;
struct RAM {
branches/ErmaC/Enoch/i386/libsaio/msdos.c
666666
667667
668668
669
669670
671
672
670673
674
671675
676
677
672678
673679
674680
......
699705
700706
701707
708
702709
710
711
703712
704713
705714
......
738747
739748
740749
750
741751
752
753
742754
743755
744756
745757
746758
747759
760
748761
749
762
763
750764
751765
752766
......
759773
760774
761775
776
762777
778
763779
780
764781
782
765783
766
784
785
767786
768787
769788
770789
790
771791
792
772793
773794
774795
......
787808
788809
789810
811
790812
813
814
791815
816
792817
818
793819
794820
795821
......
804830
805831
806832
833
807834
835
836
808837
809838
810839
......
817846
818847
819848
849
820850
851
852
821853
822854
823855
......
834866
835867
836868
869
837870
871
838872
873
839874
875
840876
841877
842
843
878
844879
845880
846881
......
900935
901936
902937
903
904
938
905939
906940
907941
......
927961
928962
929963
930
931
964
932965
933966
934967
struct direntry *dirp;
uint16_tvfatname[WIN_MAXLEN+2*WIN_CHARS];
if (MSDOSInitPartition (ih)<0)
{
return -1;
}
if (dirPath[0] == '/')
{
dirPath++;
}
st = (struct msdosdirstate *)(long) *dirIndex;
if (!st)
{
st->cluster = OSReadLittleInt16 ((dirp->deStartCluster),0);
st->vfatnumber = 0;
if (msdosfatbits == 32)
{
st->cluster |= ((uint32_t)OSReadLittleInt16 ((dirp->deHighClust),0)) <<16;
}
}
else
initRoot (st);
}
for (i=7;i>=0;i--)
if (dirp->deName[i]!=' ')
{
break;
}
j=i+1;
tmp[i+1]=0;
for(;i>=0;i--)
tmp[i]=(dirp->deName[i]>=128)?cp850[dirp->deName[i]-128][0]:tolower(dirp->deName[i]);
for (i=2;i>=0;i--)
if (dirp->deName[8+i]!=' ')
{
break;
}
if (i>=0)
{
tmp[j++]='.';
utf_encodestr(tmp, j, (uint8_t*)*name, 25, OSHostByteOrder() );
}
if (dirp->deAttributes & ATTR_DIRECTORY)
{
*flags = kFileTypeDirectory;
}
else
{
*flags = kFileTypeFlat;
}
// Calculate a fake timestamp using modification date and time values.
*time = ((dirp->deMDate & 0x7FFF) << 16) + dirp->deMTime;
if (infoValid)
{
*infoValid = 1;
}
return 0;
}
char devStr[12];
if (MSDOSInitPartition (ih)<0)
{
return -1;
}
if (filePath[0] == '/')
{
filePath++;
}
buf = malloc(msdosclustersize);
if (!buf)
{
}
cluster = OSReadLittleInt16 ((dirp->deStartCluster),0);
if (msdosfatbits == 32)
{
cluster |= ((uint32_t)OSReadLittleInt16 ((dirp->deHighClust),0)) <<16;
}
size = (uint32_t)OSReadLittleInt32 ((dirp->deFileSize),0);
if (size<=offset)
{
msdosreadcluster (ih, buf, msdosclustersize, &cluster);
toread=length;
if (length==0 || length>size-offset)
{
toread=size-offset;
}
wastoread=toread;
bcopy (buf+(offset%msdosclustersize),ptr,MIN((msdosclustersize-(offset%msdosclustersize)),(unsigned)toread));
ptr+=msdosclustersize-(offset%msdosclustersize);
*/
free (buf);
if (toread<0)
{
return wastoread;
}
else
{
return wastoread-toread;
}
}
long
MSDOSGetFileBlock(CICell ih, char *filePath, unsigned long long *firstBlock)
long MSDOSGetFileBlock(CICell ih, char *filePath, unsigned long long *firstBlock)
{
uint8_t *buf;
off_t cluster;
}
/* Fix up volume label. */
static void
fixLabel(uint8_t *label, char *str, long strMaxLen)
static void fixLabel(uint8_t *label, char *str, long strMaxLen)
{
inti, len;
uint16_tlabelucs[13];
}
void
MSDOSGetDescription(CICell ih, char *str, long strMaxLen)
void MSDOSGetDescription(CICell ih, char *str, long strMaxLen)
{
struct direntry*dirp;
uint8_tlabel[LABEL_LENGTH+1];

Archive Download the corresponding diff file

Revision: 2499