亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來(lái)到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關(guān)于我們
? 蟲蟲下載站

?? tfs.c

?? flash文件系統(tǒng)實(shí)現(xiàn)
?? C
?? 第 1 頁(yè) / 共 5 頁(yè)
字號(hào):
                    alreadyran = 1;                    break;                }            }        }        else            continue;           /* No BRUN flag set. */        if (alreadyran) {       /* BRUN flag set, but file has already      */            continue;           /* been run.                                */        }        err = TFS_OKAY;        argv[0] = fname;        /* At this point we know the file is a BRUN type, so just see if         * the query should precede the run...         */        if (fp->flags & TFS_QRYBRUN) {            char query[TFSNAMESIZE+8];            sprintf(query,"%s?",fname);            if (pollConsole(query))                continue;        }        /* Increase the size of the ranlist[] table and add the file that         * is about to be run to that list...         */        rancnt++;        rp = (struct tfsran*)realloc((char *)ranlist,            rancnt*sizeof(struct tfsran));        if (!rp) {            if (ranlist)                free((char *)ranlist);            printf("tfsrunboot() runlist realloc failure\n");            return(-1);        }        ranlist = rp;        strcpy(ranlist[rancnt-1].name,fname);        /* Run the executable... */        if ((err = tfsrun(argv,0)) != TFS_OKAY)            printf("%s: %s\n",fname,tfserrmsg(err));        /* If flash has been modified, then we must re-run tfsreorder() and         * start over...         */        if (fmodcnt != tfsFmodCount) {            if ((err = tfsreorder()) < 0) {                printf("tfsrunboot() reorder2: %s\n",tfserrmsg(err));                return(err);            }            fmodcnt = tfsFmodCount;            goto restartloop;        }    }    if (ranlist)        free((char *)ranlist);    return(rancnt);}/* tfsreorder(): *  Populate the tfsAlist[] array with the list of currently active file *  pointers, but put in alphabetical (lexicographical using strcmp()) order *  based on the filename. *  Note that after each file addition/deletion, this must be re-run. */inttfsreorder(void){    TFILE   *fp;    TDEV    *tdp;    int     i, j, tot;    /* Determine how many valid files exist, and create tfsAlist array: */    tot = 0;    for(tdp=tfsDeviceTbl;tdp->start != TFSEOT;tdp++) {        fp = (TFILE *)tdp->start;        while(validtfshdr(fp)) {            if (TFS_FILEEXISTS(fp))                tot++;            fp = nextfp(fp,tdp);        }    }    /* If tfsAlist already exists, and is already big enough, then     * don't do any allocation; otherwise, create the array with one extra     * slot for a NULL pointer used elsewhere as an end-of-list indicator.     */    if (tot > tfsAlistSize) {        tfsAlist = (TFILE **)realloc((char *)tfsAlist,            (tot+1) * sizeof(TFILE **));        if (!tfsAlist) {            tfsAlistSize = 0;            return(TFSERR_MEMFAIL);        }        tfsAlistSize = tot;    }    /* Clear the entire table (plus the extra one at the end): */    for(i=0;i<=tot;i++)        tfsAlist[i] = (TFILE *)0;    /* Populate tfsAlist[] with a pointer to each active file     * in flash as they exist in memory...     */    i = 0;    for(tdp=tfsDeviceTbl;tdp->start != TFSEOT;tdp++) {        fp = (TFILE *)tdp->start;        while(validtfshdr(fp)) {            if (TFS_FILEEXISTS(fp)) {                tfsAlist[i++] = fp;            }            fp = nextfp(fp,tdp);        }    }    /* Now run a bubble sort on that list based on the lexicographical     * ordering returned by strcmp...     */    for(i=1;i<tot;++i) {        for(j=tot-1;j>=i;--j) {            if (strcmp(TFS_NAME(tfsAlist[j-1]),TFS_NAME(tfsAlist[j])) > 0) {                fp = tfsAlist[j-1];                tfsAlist[j-1] = tfsAlist[j];                tfsAlist[j] = fp;            }        }    }    return(tot);}/* tfsheadroom(): * Based on the current offset into the file specified by the incoming * descriptor, return the gap between the current offset and the end * of the file. */static longtfsheadroom(int fd){    struct tfsdat *tdat;    if ((fd < 0) || (fd >= TFS_MAXOPEN))        return(TFSERR_BADARG);    tdat = &tfsSlots[fd];    if (tdat->flagmode & TFS_RDONLY)        return(tdat->hdr.filsize - tdat->offset);    else        return(tdat->hwp - tdat->offset);}/* tfstell(): *  Return the offset into the file that is specified by the incoming *  descriptor. *  MONLIB NOTICE: this function is accessible through monlib.c. */longtfstell(int fd){    if ((fd < 0) || (fd >= TFS_MAXOPEN))        return(TFSERR_BADARG);    return(tfsSlots[fd].offset);}/* tfscompare(): *  Compare the content of the file specified by tfp with the content pointed *  to by the remaining arguments.  If identical, return 0; else return -1. */static inttfscompare(TFILE *tfp,char *name, char *info, char *flags, uchar *src, int size){    char flgbuf[16];    /* Compare size, name, info field, flags and data: */    /* Size... */    if (TFS_SIZE(tfp) != size)        return(-1);    /* Name... */    if (strcmp(name,TFS_NAME(tfp)))        return(-1);    /* Info field... */    if (info) {        if (strcmp(info,TFS_INFO(tfp)))            return(-1);    }    else {        if (TFS_INFO(tfp)[0] != 0)            return(-1);    }    /* Flags... */    tfsflagsbtoa(TFS_FLAGS(tfp),flgbuf);    if (flags) {        if (strcmp(flags,flgbuf))            return(-1);    }    else if (flgbuf[0] != 0)        return(-1);        /* Data... */    if (memcmp(TFS_BASE(tfp),(char *)src,size))         return(-1);    return(0);}/* tfsinit(): *  Clear out all the flash that is dedicated to the file system. *  This removes all currently stored files and erases the flash. *  MONLIB NOTICE: this function is accessible through monlib.c. */int_tfsinit(TDEV *tdpin){    int     ret;    TDEV *tdp;    /* Step through the table of TFS devices and erase each sector... */    for(tdp=tfsDeviceTbl;tdp->start != TFSEOT;tdp++) {        if (!tdpin || (tdp == tdpin)) {            ret = tfsflasheraseall(tdp);            if (ret != TFS_OKAY)                return(ret);        }    }    return(TFS_OKAY);}inttfsinit(void){    if (tfsTrace > 0)        printf("tfsinit()\n");    return(_tfsinit(0));}/* tfsSpaceErased(): *  Return 0 if the space pointed to by the incoming arguments is not *  erased; else 1. */inttfsSpaceErased(uchar *begin,int size){    uchar   *end;    end = begin+size;    while(begin < end) {        if (*begin != 0xff)            return(0);        begin++;    }    return(1);}/* tfsFtot(): *  Return the number of files in a device, or all devices if tdpin is null. */inttfsFtot(TDEV *tdpin){    int     ftot;    TFILE   *fp;    TDEV    *tdp;    ftot = 0;    for(tdp=tfsDeviceTbl;tdp->start != TFSEOT;tdp++) {        if (!tdpin || (tdpin == tdp)) {            fp = (TFILE *)tdp->start;            while (fp->hdrsize != ERASED16) {                ftot++;                fp = nextfp(fp,tdp);            }        }    }    return(ftot);}/* tfsFileIsOpened(): *  Return 1 if file is currently opened; else 0. */inttfsFileIsOpened(char *name){    int  i;    struct  tfsdat *slot;    slot = tfsSlots;    for (i=0;i<TFS_MAXOPEN;i++,slot++) {        if ((slot->offset >= 0) && !strcmp(slot->hdr.name,name))            return(1);    }    return(0);}/* tfsunopen(): *  If the incoming file descriptor is valid, mark that file as no-longer *  opened and return TFS_OKAY; else return TFSERR_BADARG. *  descriptor. */static longtfsunopen(int fd){    if ((fd < 0) || (fd >= TFS_MAXOPEN))        return(TFSERR_BADARG);    if (tfsSlots[fd].offset == -1)        return(TFSERR_BADARG);    tfsSlots[fd].offset = -1;    return(TFS_OKAY);}/* tfsctrl(): *  Provides an ioctl-like interface to tfs. *  Requests supported: *      TFS_ERRMSG:     Return error message (char *) corresponding to *                      the incoming error number (arg1). *      TFS_MEMUSE:     Return the total amount of memory currently in use by *                      TFS. *      TFS_MEMAVAIL:   Return the amount of memory currently avaialable for *                      use in TFS. *      TFS_MEMDEAD:    Return the amount of memory currently in use by *                      dead files in TFS. *      TFS_DEFRAG:     Mechanism for the application to issue *                      a defragmentation request. *                      Arg1: if 1, then reset after defrag is complete. *                      Arg2: verbosity level. *      TFS_TELL:       Return the offset into the file specified by the *                      incoming file descriptor (arg1). *      TFS_FATOB:      Return the binary equivalent of the TFS flags string *                      pointed to by arg1. *      TFS_FBTOA:      Return the string equivalent of the TFS flags (long) *                      in arg1, destination buffer in arg2. *      TFS_UNOPEN:     In TFS, a the data is not actually written to FLASH *                      until the tfsclose() function is called.  This argument *                      to tfsctrl() allows a file to be opened and possibly *                      written to, then unopened without actually modifying *                      the FLASH.  The value of arg1 file descriptor to  *                      apply the "unopen" to. *      TFS_TIMEFUNCS:  This ctrl call is used to tell TFS what function *                      to call for time information... *                      Arg1 is a pointer to: *                          (long)getLtime(void) *                          - Get Long Time... *                          Returns a long representation of time. *                      Arg2 is a pointer to: *                          (char *)getAtime(long tval,char *buf). *                          - Get Ascii Time... *                          If tval is zero, the buf is loaded with a string *                          representing the current time; *                          If tval is non-zero, then buf is loaded with a *                          string conversion of the value of tval. *                      Note that since it is up to these functions to  *                      make the conversion between binary version of time *                      and ascii version, we don't define the exact meaning *                      of the value returne by getBtime(). *      TFS_DOCOMMAND:  Allows the application to redefine the function *                      that is called to process each line of a script. *                      This is useful if the application has its own *                      command interpreter, but wants to use the scripting *                      facilities of the monitor. *                      Arg1 is a pointer to the docommand function to be *                      used instead of the standard; *                      Arg2 is a pointer to a location into which the current *                      docommand function pointer can be stored. *                      If arg1 is 0, load standard docommand; *                      if arg2 is 0, don't load old value. *      TFS_INITDEV:    Allows the application to initialize one of TFS's *                      devices.  Arg1 is a pointer to the device name prefix. *      TFS_DEFRAGDEV:  Allows the application to defrag one of TFS's *                      devices.  Arg1 is a pointer to the device name prefix. *      TFS_CHECKDEV:   Allows the application to check one of TFS's *                      devices.  Arg1 is a pointer to the device name prefix. * * *  MONLIB NOTICE: this function is accessible through monlib.c. */longtfsctrl(int rqst,long arg1,long arg2){    long    retval, flag;    TDEV    *tdp;    TINFO   tinfo;    if (tfsTrace > 0)        printf("tfsctrl(%d,0x%lx,0x%lx)\n",rqst,arg1,arg2);    switch(rqst) {        case TFS_ERRMSG:            retval = (long)tfserrmsg(arg1);            break;        case TFS_MEMUSE:            tfsmemuse(0,&tinfo,0);            retval = tinfo.memused;            break;        case TFS_MEMAVAIL:            tfsmemuse(0,&tinfo,0);            retval = tinfo.memfordata;            break;        case TFS_MEMDEAD:            tfsmemuse(0,&tinfo,0);

?? 快捷鍵說(shuō)明

復(fù)制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號(hào) Ctrl + =
減小字號(hào) Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
欧美精品一区二区三区在线 | 欧美综合久久久| 亚洲精品视频观看| 91小视频在线免费看| 亚洲激情校园春色| 欧美日韩夫妻久久| 日韩av一区二区三区| 精品国产一区二区三区久久久蜜月| 久久国产日韩欧美精品| 久久久美女毛片| a级高清视频欧美日韩| 欧美激情自拍偷拍| 在线视频你懂得一区二区三区| 亚洲精品伦理在线| 91精品在线免费观看| 久久aⅴ国产欧美74aaa| 国产欧美日韩精品在线| 91久久精品一区二区| 日本亚洲最大的色成网站www| 亚洲乱码国产乱码精品精98午夜| 91捆绑美女网站| 日韩激情中文字幕| 国产女人18毛片水真多成人如厕 | 韩国毛片一区二区三区| 国产精品久久久久久久久果冻传媒| 色狠狠综合天天综合综合| 日韩一区精品视频| 欧美激情综合五月色丁香 | 欧美日韩视频在线观看一区二区三区 | 亚洲第一福利视频在线| 精品噜噜噜噜久久久久久久久试看| 成人综合在线观看| 天天色图综合网| 亚洲欧美一区二区在线观看| 欧美日韩在线精品一区二区三区激情| 久久se精品一区精品二区| 亚洲欧美日韩人成在线播放| 欧美一区二区三区白人| caoporen国产精品视频| 久久精品免费观看| 一区二区三区不卡视频| 久久精品亚洲国产奇米99| 欧美日本一区二区在线观看| 国产99久久久精品| 麻豆91在线播放免费| 亚洲色图清纯唯美| 国产欧美一区二区在线| 欧美伦理电影网| 91同城在线观看| 国产精一品亚洲二区在线视频| 亚洲一区二区偷拍精品| 国产精品天干天干在观线| 亚洲人成亚洲人成在线观看图片 | 99精品视频在线观看免费| 久久丁香综合五月国产三级网站| 一区二区三区欧美久久| 中文字幕日韩一区二区| 久久久久久久久久久久久女国产乱| 欧美区视频在线观看| 91麻豆123| 成人av综合在线| 国产精品一区二区三区网站| 日本最新不卡在线| 亚洲丰满少妇videoshd| 亚洲婷婷综合久久一本伊一区| 国产亚洲精品免费| 久久婷婷成人综合色| 91精品国产福利| 欧美精品一级二级| 欧美美女黄视频| 69久久夜色精品国产69蝌蚪网| 欧美在线短视频| 欧美日韩久久不卡| 欧美亚洲高清一区二区三区不卡| 色屁屁一区二区| 91国产精品成人| 欧美主播一区二区三区| 欧美日韩综合在线免费观看| www.在线欧美| 99精品一区二区| 欧美亚洲自拍偷拍| 制服丝袜激情欧洲亚洲| 日韩三级视频中文字幕| 日韩一区二区三区电影在线观看 | 国产原创一区二区| 国产成+人+日韩+欧美+亚洲| 国产精品亚洲第一 | 色999日韩国产欧美一区二区| 成人av第一页| 91国偷自产一区二区开放时间 | 亚洲欧美日本韩国| 亚洲大片一区二区三区| 青青草精品视频| 国产精品一区专区| www.欧美日韩国产在线| 色综合天天视频在线观看| 欧美视频一区在线| 日韩三级免费观看| 国产日韩欧美亚洲| 亚洲日本一区二区| 日韩中文字幕一区二区三区| 裸体一区二区三区| 成人丝袜高跟foot| 欧美中文一区二区三区| 日韩女优视频免费观看| 久久精品人人做人人爽人人| 亚洲免费观看视频| 人人精品人人爱| a级精品国产片在线观看| 欧美日韩在线电影| 久久亚洲二区三区| 依依成人综合视频| 久久疯狂做爰流白浆xx| 91影院在线免费观看| 国产精品久久久久久妇女6080| 亚洲视频1区2区| 青青草国产精品亚洲专区无| 国产精品18久久久久久久久久久久| www.在线欧美| 欧美一区二区三区四区视频| 久久久青草青青国产亚洲免观| 亚洲欧美偷拍另类a∨色屁股| 日韩成人dvd| 99久久亚洲一区二区三区青草 | 91网站最新地址| 亚洲精品一区二区三区影院| 亚洲欧洲一区二区在线播放| 日日骚欧美日韩| 99re这里只有精品6| 欧美v亚洲v综合ⅴ国产v| 亚洲欧洲精品成人久久奇米网| 男女男精品视频网| 欧洲激情一区二区| 国产欧美一区二区在线| 蜜臀精品久久久久久蜜臀| 97精品久久久久中文字幕| 日韩精品一区二区三区在线观看 | 欧美系列日韩一区| 中文字幕一区二区三区在线播放 | 91免费在线看| 国产欧美日韩不卡免费| 首页国产欧美久久| 91国内精品野花午夜精品| 国产欧美日韩另类视频免费观看| 日韩av一区二区三区四区| 欧洲在线/亚洲| 亚洲视频网在线直播| 国产传媒日韩欧美成人| 欧美va天堂va视频va在线| 亚洲一二三区不卡| 色激情天天射综合网| 中文字幕亚洲精品在线观看| 国产精品99久久久久久久vr| 日韩欧美色综合网站| 日韩综合小视频| 欧美吞精做爰啪啪高潮| 亚洲欧美aⅴ...| 99精品视频在线播放观看| 日本一区二区高清| 国产**成人网毛片九色 | 日本vs亚洲vs韩国一区三区二区| 在线观看视频欧美| 一区二区三区不卡在线观看| 91丝袜国产在线播放| 中文字幕高清一区| 国产成人亚洲精品青草天美| 欧美v亚洲v综合ⅴ国产v| 美女视频黄频大全不卡视频在线播放| 欧美日韩黄色一区二区| 亚洲成av人片在线观看无码| 欧美日韩免费视频| 日日夜夜精品免费视频| 欧美一区二区三区四区高清| 男女性色大片免费观看一区二区| 日韩一级高清毛片| 久久99精品久久久久久久久久久久| 欧美一区二区三区精品| 久久精品国产99国产精品| 日韩精品中文字幕在线一区| 韩国精品一区二区| 国产日产欧美一区二区视频| 福利一区在线观看| 亚洲视频 欧洲视频| 色香色香欲天天天影视综合网| 亚洲欧美经典视频| 欧美日韩国产影片| 美女性感视频久久| 一区二区三区四区av| 欧美天堂一区二区三区| 日韩在线观看一区二区| 久久天堂av综合合色蜜桃网| 高清国产一区二区| 洋洋成人永久网站入口| 91精品久久久久久久久99蜜臂 | 蜜桃av一区二区在线观看| 精品电影一区二区| av一区二区三区在线| 一区二区三区在线看| 欧美浪妇xxxx高跟鞋交| 国内成人精品2018免费看|