TempleOSCDV4.12.ISO

This commit is contained in:
Terry A. Davis authored and minexew committed 2018-09-08 21:47:56 +02:00
1 parent 93ca216483
commit b84bbff6db
381 files changed
+18356 -18798

No files matched your search

+11 -11
View File
@@ -4,28 +4,28 @@ hold the file until you are done. The $LK,"CDoc",A="MN:CDoc"$
framework is convenient for this.
*/
U0 TreeSub(CDoc *doc,CDirEntry *tempde)
U0 TreeSub(CDoc *doc,CDirEntry *tmpde)
{
CDirEntry *tempde1;
while (tempde) {
tempde1=tempde->next;
if (tempde->attr & RS_ATTR_DIR) {
CDirEntry *tmpde1;
while (tmpde) {
tmpde1=tmpde->next;
if (tmpde->attr & RS_ATTR_DIR) {
DocPrint(doc,"$$TR,\"\"$$");
DocPrint(doc,"$$MA,T=\"%s\",LM=\"Cd(\\\"%s\\\");Dir;\n\"$$\n",
tempde->name,tempde->full_name);
if (tempde->sub) {
tmpde->name,tmpde->full_name);
if (tmpde->sub) {
DocPrint(doc,"$$ID,+2$$");
TreeSub(doc,tempde->sub);
TreeSub(doc,tmpde->sub);
DocPrint(doc,"$$ID,-2$$");
}
} else
DocPrint(doc,"$$LK,\"%s\",A=\"FI:%s\"$$\n",
tempde->name,tempde->full_name);
tmpde->name,tmpde->full_name);
//Note there is also a routine
//to delete an entire CDirEntry tree.
//See $LK,"DirTreeDel",A="MN:DirTreeDel"$().
DirEntryDel(tempde);
tempde=tempde1;
DirEntryDel(tmpde);
tmpde=tmpde1;
}
}
+8 -8
View File
@@ -6,16 +6,16 @@ other end.
U0 SerializeTree()
{
CDirEntry *tempde=FilesFind("/Demo/*.DD*",FUF_RECURSE);
CDirEntry *tmpde=FilesFind("/Demo/*.DD*",FUF_RECURSE);
I64 size;
U8 *ptr;
CArcCompress *arc;
LineRep1(tempde); //We have $LK,"CDirEntry",A="MN:CDirEntry"$.fullname
LineRep2(DocPut,tempde);
LineRep1(tmpde); //We have $LK,"CDirEntry",A="MN:CDirEntry"$.fullname
LineRep2(DocPut,tmpde);
"$$GREEN$$***************$$FG$$\n";
ptr=DirTreeSerialize(tempde,&size);
DirTreeDel(tempde);
ptr=DirTreeSerialize(tmpde,&size);
DirTreeDel(tmpde);
D(ptr,size);
"$$GREEN$$***************:%7d$$FG$$\n",size;
arc=CompressBuf(ptr,size);
@@ -27,9 +27,9 @@ U0 SerializeTree()
Free(arc);
D(ptr,size);
"$$GREEN$$***************:%7d$$FG$$\n",size;
tempde=DirTreeUnserialize(ptr);
LineRep2(DocPut,tempde); //We don't have $LK,"CDirEntry",A="MN:CDirEntry"$.fullname
DirTreeDel(tempde);
tmpde=DirTreeUnserialize(ptr);
LineRep2(DocPut,tmpde); //We don't have $LK,"CDirEntry",A="MN:CDirEntry"$.fullname
DirTreeDel(tmpde);
}
SerializeTree;