new
This commit is contained in:
parent
2939db38f5
commit
f56acf8081
|
|
@ -0,0 +1,194 @@
|
||||||
|
/**************************************************************************
|
||||||
|
***************************************************************************
|
||||||
|
|
||||||
|
W E G A - Quelle (C) TU KMSt / ZFT/KEAW Abt. WAE - 1988
|
||||||
|
Programm: dosopn.c
|
||||||
|
|
||||||
|
Bearbeiter : P. Hoge
|
||||||
|
Datum : 24.11.89
|
||||||
|
Version : 1.3
|
||||||
|
|
||||||
|
***************************************************************************
|
||||||
|
**************************************************************************/
|
||||||
|
|
||||||
|
#include "dos.h"
|
||||||
|
|
||||||
|
/* dosopn
|
||||||
|
* Durchmustert ein DCP-Verzeichnis,
|
||||||
|
* uebergibt die Adresse einer Struktur dostat
|
||||||
|
* fuer die durch path beschriebene Datei.
|
||||||
|
* Liefert -1 bei Fehler und 0 wenn nicht gefunden
|
||||||
|
*/
|
||||||
|
dosopn(path,dp,stp)
|
||||||
|
register char *path;
|
||||||
|
register struct dosdisc *dp;
|
||||||
|
register struct dostat *stp;
|
||||||
|
{
|
||||||
|
char s[LMAX],*p;
|
||||||
|
long dadr;
|
||||||
|
unsigned next,dosnxt();
|
||||||
|
int res,dn;
|
||||||
|
char *strchr();
|
||||||
|
|
||||||
|
dn = dp->dirnum;
|
||||||
|
dadr = dp->maindir;
|
||||||
|
next = 0;
|
||||||
|
strcpy(s,path);
|
||||||
|
path = s;
|
||||||
|
if (path[0] == '/')
|
||||||
|
path++;
|
||||||
|
while (path != 0 && path[0] != '\0') {
|
||||||
|
if ((p=strchr(path,'/')) != 0)
|
||||||
|
path[strlen(path)-strlen(p++)] = '\0';
|
||||||
|
while (-1) {
|
||||||
|
if ((res=dosrde(dp->fd,path,dn,dadr,stp)) < 0)
|
||||||
|
return(res);
|
||||||
|
if (res == 1) {
|
||||||
|
next = stp->first;
|
||||||
|
dadr = DOSADR(next,dp->clustsiz)+dp->data;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
dn = dp->clustsiz/32;
|
||||||
|
if ((next=dosnxt(dp->fd,next,dp->fat1,dp->fatlen))<1)
|
||||||
|
return(0);
|
||||||
|
dadr = DOSADR(next,dp->clustsiz)+dp->data;
|
||||||
|
}
|
||||||
|
path = p;
|
||||||
|
}
|
||||||
|
return(1);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/* dosrde
|
||||||
|
* Sucht einen Verzeichniseintrag und
|
||||||
|
* belegt eine Struktur dostat mit Werten
|
||||||
|
*/
|
||||||
|
dosrde(fd,fn,dnum,adr,stp)
|
||||||
|
int fd;
|
||||||
|
register char *fn; /* Name des zu suchenden DCP-Files */
|
||||||
|
int dnum; /* max. moegliche Anzahl von Verzeichniseintraegn */
|
||||||
|
register long adr; /* Startadresse des Verzeichnisses */
|
||||||
|
register struct dostat *stp;
|
||||||
|
{
|
||||||
|
int res;
|
||||||
|
char *strchr(),*ext, c='\0';
|
||||||
|
|
||||||
|
lseek(fd,adr,0);
|
||||||
|
ext = strchr(fn,'.');
|
||||||
|
if (ext)
|
||||||
|
ext++;
|
||||||
|
else
|
||||||
|
ext = &c;
|
||||||
|
|
||||||
|
while ((res=getde(fd,stp)) > 0 ) {
|
||||||
|
if (dnum-- == 0)
|
||||||
|
return(0);
|
||||||
|
if (ncmp(fn, stp->name, 8) && ncmp(ext, &stp->name[8], 3))
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
return(res);
|
||||||
|
}
|
||||||
|
|
||||||
|
ncmp(a,b,n)
|
||||||
|
register char *a,*b;
|
||||||
|
register int n;
|
||||||
|
{
|
||||||
|
while (n--) {
|
||||||
|
if (*b == 0x20 && (*a == '\0' || *a == '.'))
|
||||||
|
break;
|
||||||
|
if (*a++ != *b++)
|
||||||
|
return(0);
|
||||||
|
}
|
||||||
|
return(1);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/* getde
|
||||||
|
* liest einen 32-Byte Verzeichniseintrag und belegt
|
||||||
|
* dostat mit den Dateiparametern.
|
||||||
|
* Beachte: Der Bytezaehler muss vorher auf das erste
|
||||||
|
* Byte des Eintrages zeigen !
|
||||||
|
* Die Funktion liefert 0, wenn keine gueltigen Eintraege
|
||||||
|
* mehr im Verzeichnis stehen und -1 bei Lesefehler.
|
||||||
|
*/
|
||||||
|
getde(fd,stat_buf)
|
||||||
|
register int fd;
|
||||||
|
register struct dostat *stat_buf;
|
||||||
|
{
|
||||||
|
register int i;
|
||||||
|
register unsigned date,time;
|
||||||
|
unsigned char dirbuf[32];
|
||||||
|
|
||||||
|
if (read(fd,dirbuf,32)!=32)
|
||||||
|
return(-1);
|
||||||
|
|
||||||
|
for (i=0;i<11;i++)
|
||||||
|
stat_buf->name[i]=dirbuf[i];
|
||||||
|
stat_buf->name[i]='\0';
|
||||||
|
|
||||||
|
if (stat_buf->name[0]=='\0')
|
||||||
|
return(0);
|
||||||
|
|
||||||
|
if (dirbuf[11]&0x01)
|
||||||
|
stat_buf->flag = RO;
|
||||||
|
else
|
||||||
|
stat_buf->flag = RW;
|
||||||
|
stat_buf->attr = dirbuf[11];
|
||||||
|
if (dirbuf[11]&0x02)
|
||||||
|
stat_buf->mode = _BLOCKED;
|
||||||
|
else if (dirbuf[11]&0x04)
|
||||||
|
stat_buf->mode = _SYSDAT;
|
||||||
|
else if (dirbuf[11]&0x10)
|
||||||
|
stat_buf->mode = _SDIR;
|
||||||
|
else
|
||||||
|
stat_buf->mode = _FILE;
|
||||||
|
|
||||||
|
stat_buf->first=dirbuf[27]*256+dirbuf[26];
|
||||||
|
stat_buf->dim=dirbuf[31]*16777216+dirbuf[30]*65536+dirbuf[29]*256+dirbuf[28];
|
||||||
|
date=dirbuf[25]*256 + dirbuf[24];
|
||||||
|
time=dirbuf[23]*256 + dirbuf[22];
|
||||||
|
|
||||||
|
stat_buf->date.year=date/512 + 1980;
|
||||||
|
stat_buf->date.month=(date&0x01ff)/32;
|
||||||
|
stat_buf->date.day=date&0x001f;
|
||||||
|
|
||||||
|
stat_buf->time.hour=time/2048;
|
||||||
|
stat_buf->time.min=(time&0x07ff)/32;
|
||||||
|
stat_buf->time.sec=(time&0x001f)*2;
|
||||||
|
return(1);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/* Bereitstellen der naechsten Clusternummer
|
||||||
|
* liefert 0 bei Dateiende
|
||||||
|
*/
|
||||||
|
unsigned dosnxt(fd,first,fat,fatlen)
|
||||||
|
register int fd;
|
||||||
|
register unsigned first;
|
||||||
|
register unsigned long fat;
|
||||||
|
register int fatlen;
|
||||||
|
{
|
||||||
|
register unsigned nxt;
|
||||||
|
unsigned char b[2];
|
||||||
|
|
||||||
|
if (fatlen == 12) {
|
||||||
|
lseek(fd,fat+(long)(1.5*first),0);
|
||||||
|
read(fd,b,2);
|
||||||
|
|
||||||
|
if (first % 2 == 0)
|
||||||
|
nxt = (b[1]&0x0f)*256 + b[0];
|
||||||
|
else
|
||||||
|
nxt = b[1]*16 + b[0]/16;
|
||||||
|
|
||||||
|
if (nxt >= 0x0ff8 && nxt <= 0x0fff)
|
||||||
|
nxt = 0;
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
lseek(fd,fat+(long)(2*first),0);
|
||||||
|
read(fd,b,2);
|
||||||
|
nxt = b[1]*256+b[0];
|
||||||
|
if (nxt >= 0xfff8 && nxt <= 0xffff)
|
||||||
|
nxt = 0;
|
||||||
|
}
|
||||||
|
return(nxt);
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,89 @@
|
||||||
|
/**************************************************************************
|
||||||
|
***************************************************************************
|
||||||
|
|
||||||
|
W E G A - Quelle (C) TU KMSt / ZFT/KEAW Abt. WAE - 1988
|
||||||
|
Programm: dosplit.c
|
||||||
|
|
||||||
|
Bearbeiter : P. Hoge
|
||||||
|
Datum : 24.11.89
|
||||||
|
Version : 1.3
|
||||||
|
|
||||||
|
***************************************************************************
|
||||||
|
**************************************************************************/
|
||||||
|
|
||||||
|
#include <stdio.h>
|
||||||
|
#include <ctype.h>
|
||||||
|
#include "dos.h"
|
||||||
|
|
||||||
|
#define STANDARD "/etc/default/dos"
|
||||||
|
|
||||||
|
/* dosplit
|
||||||
|
* Teilt einen Pfad in die DCP- und
|
||||||
|
* WEGA-Bestandteile.
|
||||||
|
* Dabei wird das Verzeichnis /etc/default/dos
|
||||||
|
* ausgewertet und im DCP-Pfad werden
|
||||||
|
* Klein- in Grossbuchstaben umgewandelt.
|
||||||
|
* Bei Fehler liefert dosplit -1
|
||||||
|
*/
|
||||||
|
|
||||||
|
dosplit(path,upath,dpath)
|
||||||
|
register char *path,*upath,*dpath;
|
||||||
|
{
|
||||||
|
char *p,line[LMAX],lw,*strrchr(), *getenv();
|
||||||
|
FILE *fp;
|
||||||
|
int mlen, found=0;
|
||||||
|
|
||||||
|
strncpy(upath,path,LMAX);
|
||||||
|
upath[LMAX-1] = '\0';
|
||||||
|
*dpath = '\0';
|
||||||
|
|
||||||
|
strcpy(line, getenv("HOME"));
|
||||||
|
strcat(line, "/.dos");
|
||||||
|
|
||||||
|
if ((p=strrchr(path,':')) == '\0')
|
||||||
|
/* kein DCP-Pfad */
|
||||||
|
return(2); /* keine DCP-Datei angegeben */
|
||||||
|
|
||||||
|
if ((mlen = strlen(path) - strlen(p)) == 1) {
|
||||||
|
/* vor ':' ist Laufwerksbuchstabe angegeben */
|
||||||
|
|
||||||
|
if ((fp=fopen(line, "r")) == 0) {
|
||||||
|
if ((fp=fopen(STANDARD,"r")) == 0) {
|
||||||
|
fprintf(stderr,"%s nicht eingerichtet\n",STANDARD);
|
||||||
|
return(-1);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
p--;
|
||||||
|
lw = toupper(*p);
|
||||||
|
p += 2;
|
||||||
|
if (*p == '/')
|
||||||
|
p++;
|
||||||
|
while (fgets(line,LMAX,fp) != 0) {
|
||||||
|
if (line[0] == lw && strlen(line) > 3) {
|
||||||
|
line[strlen(line)-1] = '\0';
|
||||||
|
strcpy(upath,line+2);
|
||||||
|
found++;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (!found) {
|
||||||
|
fprintf(stderr,"Laufwerk %c: nicht definiert\n",lw);
|
||||||
|
return(-1);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
if (mlen >= LMAX)
|
||||||
|
upath[LMAX-1] = '\0';
|
||||||
|
else
|
||||||
|
upath[mlen] = '\0';
|
||||||
|
++p;
|
||||||
|
if (*p == '/')
|
||||||
|
p++;
|
||||||
|
}
|
||||||
|
strncpy(dpath,p,LMAX);
|
||||||
|
dpath[LMAX-1] = '\n';
|
||||||
|
while (*dpath != '\0')
|
||||||
|
*dpath++ = islower(*dpath) ? toupper(*dpath) : *dpath;
|
||||||
|
/* Der DCP-Pfad enthaelt mindestens das Stammverzeichnis */
|
||||||
|
return(1);
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,73 @@
|
||||||
|
/**************************************************************************
|
||||||
|
***************************************************************************
|
||||||
|
|
||||||
|
W E G A - Quelle (C) TU KMSt / ZFT/KEAW Abt. WAE - 1988
|
||||||
|
Programm: dosrm.c
|
||||||
|
|
||||||
|
Bearbeiter : P. Hoge
|
||||||
|
Datum : 24.11.89
|
||||||
|
Version : 1.3
|
||||||
|
|
||||||
|
***************************************************************************
|
||||||
|
|
||||||
|
Loeschen von DOS-Dateien
|
||||||
|
|
||||||
|
***************************************************************************
|
||||||
|
**************************************************************************/
|
||||||
|
|
||||||
|
#include <stdio.h>
|
||||||
|
#include <sys/types.h>
|
||||||
|
#include <sys/stat.h>
|
||||||
|
#include "dos.h"
|
||||||
|
|
||||||
|
main(argc,argv)
|
||||||
|
register char **argv;
|
||||||
|
{
|
||||||
|
register char *arg0 = argv[0];
|
||||||
|
register int status = 0,res;
|
||||||
|
char upath[LMAX],dpath[LMAX];
|
||||||
|
struct dosdisc dos;
|
||||||
|
struct dostat dstat;
|
||||||
|
|
||||||
|
argc--;
|
||||||
|
if (argc == 0) {
|
||||||
|
fprintf(stderr,"usage: dosrm dosdev:filename [dosdev:filename] [...]\n");
|
||||||
|
exit(1);
|
||||||
|
}
|
||||||
|
while (argc-- > 0) {
|
||||||
|
if (dosplit(*++argv,upath,dpath) < 0) {
|
||||||
|
status = 2;
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
if (*dpath == '\0') {
|
||||||
|
fprintf(stderr,"%s: %s kein DCP-Pfad\n",arg0,upath);
|
||||||
|
status = 2;
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
if (dosdev(upath,2,&dos) < 0) {
|
||||||
|
fprintf(stderr,"%s: Fehler in %s\n",arg0,upath);
|
||||||
|
status = 2;
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
res = dosdel(dpath,&dos);
|
||||||
|
switch (res) {
|
||||||
|
case 0:
|
||||||
|
fprintf(stderr,"%s: %s nicht gefunden\n",arg0,dpath);
|
||||||
|
status = 2;
|
||||||
|
break;
|
||||||
|
case -1:
|
||||||
|
fprintf(stderr,"%s: %s - Lesefehler\n",arg0,upath);
|
||||||
|
status = 2;
|
||||||
|
break;
|
||||||
|
case -2:
|
||||||
|
fprintf(stderr,"%s: %s - Schreibfehler\n",arg0,upath);
|
||||||
|
status = 2;
|
||||||
|
break;
|
||||||
|
case -3:
|
||||||
|
fprintf(stderr,"%s: %s ist Verzeichnis oder schreibgeschuetzt\n",arg0,dpath);
|
||||||
|
status = 2;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
exit(status);
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,172 @@
|
||||||
|
/**************************************************************************
|
||||||
|
***************************************************************************
|
||||||
|
|
||||||
|
W E G A - Quelle (C) TU KMSt / ZFT/KEAW Abt. WAE - 1988
|
||||||
|
Programm: dosrmdir.c
|
||||||
|
|
||||||
|
Bearbeiter : P. Hoge
|
||||||
|
Datum : 24.11.89
|
||||||
|
Version : 1.3
|
||||||
|
|
||||||
|
***************************************************************************
|
||||||
|
|
||||||
|
Loeschen von DOS-Verzeichnissen
|
||||||
|
|
||||||
|
***************************************************************************
|
||||||
|
**************************************************************************/
|
||||||
|
|
||||||
|
#include <stdio.h>
|
||||||
|
#include <sys/types.h>
|
||||||
|
#include <sys/stat.h>
|
||||||
|
#include "dos.h"
|
||||||
|
|
||||||
|
main(argc,argv)
|
||||||
|
register char **argv;
|
||||||
|
{
|
||||||
|
register char *arg0 = argv[0];
|
||||||
|
register int status = 0,res;
|
||||||
|
char upath[LMAX],dpath[LMAX];
|
||||||
|
struct dosdisc dos;
|
||||||
|
struct dostat dstat;
|
||||||
|
|
||||||
|
argc--;
|
||||||
|
if (argc == 0) {
|
||||||
|
fprintf(stderr,"usage: dosrmdir dosdev:dirname\n");
|
||||||
|
exit(1);
|
||||||
|
}
|
||||||
|
while (argc-- > 0) {
|
||||||
|
if ((res=dosplit(*++argv,upath,dpath)) < 0) {
|
||||||
|
status = 2;
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
if (res == 2) {
|
||||||
|
strcpy(dpath, "/bin/rmdir ");
|
||||||
|
strcat(dpath, upath);
|
||||||
|
status = system(dpath);
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
if (*dpath == '\0') {
|
||||||
|
fprintf(stderr,"%s: falsches Verzeichnis angegeben\n",arg0);
|
||||||
|
status = 2;
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
if (dosdev(upath,2,&dos) < 0) {
|
||||||
|
fprintf(stderr,"%s: Fehler in %s\n",arg0,upath);
|
||||||
|
status = 2;
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
res = deldir(dpath,&dos);
|
||||||
|
switch (res) {
|
||||||
|
case 0:
|
||||||
|
fprintf(stderr,"%s: %s nicht gefunden\n",arg0,dpath);
|
||||||
|
status = 2;
|
||||||
|
break;
|
||||||
|
case -1:
|
||||||
|
fprintf(stderr,"%s: %s - Lesefehler\n",arg0,upath);
|
||||||
|
status = 2;
|
||||||
|
break;
|
||||||
|
case -2:
|
||||||
|
fprintf(stderr,"%s: %s - Schreibfehler\n",arg0,upath);
|
||||||
|
status = 2;
|
||||||
|
break;
|
||||||
|
case -3:
|
||||||
|
fprintf(stderr,"%s: %s ist kein Verzeichnis oder schreibgeschuetzt\n",arg0,dpath);
|
||||||
|
status = 2;
|
||||||
|
break;
|
||||||
|
case -4:
|
||||||
|
fprintf(stderr,"%s: %s ist nicht leer\n",arg0,dpath);
|
||||||
|
status = 2;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
exit(status);
|
||||||
|
}
|
||||||
|
|
||||||
|
/* deldir
|
||||||
|
* Loescht das DCP-Verzeichnis dir auf dem Datentraeger dp.
|
||||||
|
* Liefert 0 ,wenn nicht gefuden ,
|
||||||
|
* -1 ,bei Lesefehler ,
|
||||||
|
* -2 ,bei Schreibfehler
|
||||||
|
* -3 ,falls dir kein Verzeichnis bzw
|
||||||
|
* schreibgeschuetzt und
|
||||||
|
* -4 ,falls dir nicht leer ist.
|
||||||
|
*/
|
||||||
|
deldir(dir,dp)
|
||||||
|
char *dir;
|
||||||
|
struct dosdisc *dp;
|
||||||
|
{
|
||||||
|
int fatdel(),res,i,z=1,empty=1;
|
||||||
|
struct dostat fnrec,dirrec;
|
||||||
|
long adr,eadr;
|
||||||
|
unsigned char c,delsign=0xe5;
|
||||||
|
char *file,*p,*strchr();
|
||||||
|
unsigned dnum,nxt,dosnxt();
|
||||||
|
|
||||||
|
if ((res=dosopn(dir,dp,&fnrec))<1)
|
||||||
|
return(res);
|
||||||
|
if (fnrec.mode != _SDIR || fnrec.flag == RO)
|
||||||
|
return(-3);
|
||||||
|
file = dir;
|
||||||
|
while ((p=strchr(file,'/')) != 0)
|
||||||
|
file = ++p;
|
||||||
|
dir[strlen(dir)-strlen(file)-1] = '\0';
|
||||||
|
|
||||||
|
if (file == dir) {
|
||||||
|
dnum = dp->dirnum;
|
||||||
|
adr = dp->maindir;
|
||||||
|
nxt = 0;
|
||||||
|
}
|
||||||
|
else { /* Das uebergeordnete Verzeichnis ist nicht das
|
||||||
|
* Stammverzeichnis
|
||||||
|
*/
|
||||||
|
if ((res=dosopn(dir,dp,&dirrec)) < 1)
|
||||||
|
return(res);
|
||||||
|
adr = DOSADR(dirrec.first,dp->clustsiz)+dp->data;
|
||||||
|
nxt = dirrec.first;
|
||||||
|
/* Bestimmen der Anzahl von Verzeichnisclustern */
|
||||||
|
while ((nxt=dosnxt(dp->fd,nxt,dp->fat1,dp->fatlen)) > 0)
|
||||||
|
z++;
|
||||||
|
dnum = dp->clustsiz/32;
|
||||||
|
}
|
||||||
|
/* Suchen des zu loeschenden Eintrages */
|
||||||
|
for (i=0;i<z;i++) {
|
||||||
|
if ((res=dosrde(dp->fd,file,dnum,adr,&dirrec)) < 0)
|
||||||
|
return(res);
|
||||||
|
else
|
||||||
|
eadr = lseek(dp->fd,(long)-32,1);
|
||||||
|
if (nxt != 0) {
|
||||||
|
if ((nxt=dosnxt(dp->fd,nxt,dp->fat1,dp->fatlen)) < 1)
|
||||||
|
break;
|
||||||
|
/* naechsten Cluster lesen */
|
||||||
|
adr = DOSADR(nxt,dp->clustsiz)+dp->data;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
adr = DOSADR(fnrec.first,dp->clustsiz)+dp->data;
|
||||||
|
nxt = fnrec.first;
|
||||||
|
z = 1;
|
||||||
|
while ((nxt=dosnxt(dp->fd,nxt,dp->fat1,dp->fatlen)) > 0)
|
||||||
|
z++;
|
||||||
|
lseek(dp->fd,adr,0);
|
||||||
|
for (i=0;i<z;i++) {
|
||||||
|
while ((res=getde(dp->fd,&dirrec)) > 0 && empty)
|
||||||
|
if ((c=dirrec.name[0]) != 0xe5 && c != '.')
|
||||||
|
empty--;
|
||||||
|
if (res < 0)
|
||||||
|
return(res);
|
||||||
|
if (!empty)
|
||||||
|
return(-4);
|
||||||
|
if (res == 0)
|
||||||
|
break;
|
||||||
|
if ((nxt=dosnxt(dp->fd,nxt,dp->fat1,dp->fatlen)) < 1)
|
||||||
|
break;
|
||||||
|
else {
|
||||||
|
adr = DOSADR(nxt,dp->clustsiz)+dp->data;
|
||||||
|
lseek(dp->fd,adr,0);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
/* Verzeichnis ist leer -> als geloescht markieren */
|
||||||
|
lseek(dp->fd,eadr,0);
|
||||||
|
if (write(dp->fd,&delsign,1) != 1)
|
||||||
|
return(-2);
|
||||||
|
return(fatdel(&fnrec,dp));
|
||||||
|
}
|
||||||
Loading…
Reference in New Issue