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

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? bload.c

?? clips源代碼
?? C
?? 第 1 頁 / 共 2 頁
字號:
   /*******************************************************/   /*      "C" Language Integrated Production System      */   /*                                                     */   /*               CLIPS Version 6.24  06/05/06          */   /*                                                     */   /*                    BLOAD MODULE                     */   /*******************************************************//*************************************************************//* Purpose: Provides core routines for loading constructs    *//*   from a binary file.                                     *//*                                                           *//* Principal Programmer(s):                                  *//*      Gary D. Riley                                        *//*      Brian L. Donnell                                     *//*                                                           *//* Contributing Programmer(s):                               *//*                                                           *//* Revision History:                                         *//*                                                           *//*      6.24: Renamed BOOLEAN macro type to intBool.         *//*                                                           *//*************************************************************/#define _BLOAD_SOURCE_#include "setup.h"#include "argacces.h"#include "bsave.h"#include "constrct.h"#include "cstrnbin.h"#include "envrnmnt.h"#include "exprnpsr.h"#include "memalloc.h"#include "router.h"#include "utility.h"#include "bload.h"#if (BLOAD || BLOAD_ONLY || BLOAD_AND_BSAVE)/***************************************//* LOCAL INTERNAL FUNCTION DEFINITIONS *//***************************************/   static struct FunctionDefinition **ReadNeededFunctions(void *,long *,int *);   static struct FunctionDefinition  *FastFindFunction(void *,char *,struct FunctionDefinition *);   static int                         ClearBload(void *);   static void                        AbortBload(void *);   static int                         BloadOutOfMemoryFunction(void *,size_t);   static void                        DeallocateBloadData(void *);/**********************************************//* InitializeBloadData: Allocates environment *//*    data for the bload command.             *//**********************************************/globle void InitializeBloadData(  void *theEnv)  {   AllocateEnvironmentData(theEnv,BLOAD_DATA,sizeof(struct bloadData),NULL);   AddEnvironmentCleanupFunction(theEnv,"bload",DeallocateBloadData,-1500);   BloadData(theEnv)->BinaryPrefixID = "\1\2\3\4CLIPS";   BloadData(theEnv)->BinaryVersionID = "V6.30";  }  /************************************************//* DeallocateBloadData: Deallocates environment *//*    data for the bload command.               *//************************************************/static void DeallocateBloadData(  void *theEnv)  {      DeallocateCallList(theEnv,BloadData(theEnv)->BeforeBloadFunctions);   DeallocateCallList(theEnv,BloadData(theEnv)->AfterBloadFunctions);   DeallocateCallList(theEnv,BloadData(theEnv)->ClearBloadReadyFunctions);   DeallocateCallList(theEnv,BloadData(theEnv)->AbortBloadFunctions);  }/******************************//* EnvBload: C access routine *//*   for the bload command.   *//******************************/globle int EnvBload(  void *theEnv,  char *fileName)  {   long numberOfFunctions;   unsigned long space;   int error;   char IDbuffer[20];      char constructBuffer[CONSTRUCT_HEADER_SIZE];   struct BinaryItem *biPtr;   struct callFunctionItem *bfPtr;   /*================*/   /* Open the file. */   /*================*/   if (GenOpenReadBinary(theEnv,"bload",fileName) == 0) return(FALSE);   /*=====================================*/   /* Determine if this is a binary file. */   /*=====================================*/   GenReadBinary(theEnv,IDbuffer,(unsigned long) strlen(BloadData(theEnv)->BinaryPrefixID) + 1);   if (strcmp(IDbuffer,BloadData(theEnv)->BinaryPrefixID) != 0)     {      PrintErrorID(theEnv,"BLOAD",2,FALSE);      EnvPrintRouter(theEnv,WERROR,"File ");      EnvPrintRouter(theEnv,WERROR,fileName);      EnvPrintRouter(theEnv,WERROR," is not a binary construct file.\n");      GenCloseBinary(theEnv);      return(FALSE);     }   /*=======================================*/   /* Determine if it's a binary file using */   /* a format from a different version.    */   /*=======================================*/   GenReadBinary(theEnv,IDbuffer,(unsigned long) strlen(BloadData(theEnv)->BinaryVersionID) + 1);   if (strcmp(IDbuffer,BloadData(theEnv)->BinaryVersionID) != 0)     {      PrintErrorID(theEnv,"BLOAD",3,FALSE);      EnvPrintRouter(theEnv,WERROR,"File ");      EnvPrintRouter(theEnv,WERROR,fileName);      EnvPrintRouter(theEnv,WERROR," is an incompatible binary construct file.\n");      GenCloseBinary(theEnv);      return(FALSE);     }        /*====================*/   /* Clear environment. */   /*====================*/   if (BloadData(theEnv)->BloadActive)     {      if (ClearBload(theEnv) == FALSE)        {         GenCloseBinary(theEnv);         return(FALSE);        }     }   /*=================================*/   /* Determine if the KB environment */   /* was successfully cleared.       */   /*=================================*/   if (ClearReady(theEnv) == FALSE)     {      GenCloseBinary(theEnv);      EnvPrintRouter(theEnv,WERROR,"The ");      EnvPrintRouter(theEnv,WERROR,APPLICATION_NAME);      EnvPrintRouter(theEnv,WERROR," environment could not be cleared.\n");      EnvPrintRouter(theEnv,WERROR,"Binary load cannot continue.\n");      return(FALSE);     }   /*==================================*/   /* Call the list of functions to be */   /* executed before a bload occurs.  */   /*==================================*/   for (bfPtr = BloadData(theEnv)->BeforeBloadFunctions;        bfPtr != NULL;        bfPtr = bfPtr->next)     {       if (bfPtr->environmentAware)        { (*bfPtr->func)(theEnv); }      else                    { (* (void (*)(void)) bfPtr->func)(); }     }   /*====================================================*/   /* Read in the functions needed by this binary image. */   /*====================================================*/   BloadData(theEnv)->FunctionArray = ReadNeededFunctions(theEnv,&numberOfFunctions,&error);   if (error)     {      GenCloseBinary(theEnv);      AbortBload(theEnv);      return(FALSE);     }   /*================================================*/   /* Read in the atoms needed by this binary image. */   /*================================================*/   ReadNeededAtomicValues(theEnv);   /*===========================================*/   /* Determine the number of expressions to be */   /* read and allocate the appropriate space   */   /*===========================================*/   AllocateExpressions(theEnv);   /*==========================================================*/   /* Read in the memory requirements of the constructs stored */   /* in this binary image and allocate the necessary space    */   /*==========================================================*/   for (GenReadBinary(theEnv,constructBuffer,(unsigned long) CONSTRUCT_HEADER_SIZE);        strncmp(constructBuffer,BloadData(theEnv)->BinaryPrefixID,CONSTRUCT_HEADER_SIZE) != 0;        GenReadBinary(theEnv,constructBuffer,(unsigned long) CONSTRUCT_HEADER_SIZE))     {      intBool found;      /*================================================*/      /* Search for the construct type in the list of   */      /* binary items. If found, allocate the storage   */      /* needed by the construct for this binary image. */      /*================================================*/      found = FALSE;      for (biPtr = BsaveData(theEnv)->ListOfBinaryItems;           biPtr != NULL;           biPtr = biPtr->next)        {         if (strncmp(biPtr->name,constructBuffer,CONSTRUCT_HEADER_SIZE) == 0)           {            if (biPtr->bloadStorageFunction != NULL)              {               (*biPtr->bloadStorageFunction)(theEnv);               found = TRUE;              }            break;           }        }      /*==========================================*/      /* If the construct type wasn't found, skip */      /* the storage binary load information for  */      /* this construct.                          */      /*==========================================*/      if (! found)        {         GenReadBinary(theEnv,&space,(unsigned long) sizeof(unsigned long));         GetSeekCurBinary(theEnv,(long) space);         if (space != 0)           {            EnvPrintRouter(theEnv,WDIALOG,"\nSkipping ");            EnvPrintRouter(theEnv,WDIALOG,constructBuffer);            EnvPrintRouter(theEnv,WDIALOG," constructs because of unavailibility\n");           }        }     }   /*======================================*/   /* Refresh the pointers in expressions. */   /*======================================*/   RefreshExpressions(theEnv);   /*==========================*/   /* Read in the constraints. */   /*==========================*/   ReadNeededConstraints(theEnv);   /*======================================================*/   /* Read in the constructs stored in this binary image.  */   /*======================================================*/   for (GenReadBinary(theEnv,constructBuffer,(unsigned long) CONSTRUCT_HEADER_SIZE);        strncmp(constructBuffer,BloadData(theEnv)->BinaryPrefixID,CONSTRUCT_HEADER_SIZE) != 0;        GenReadBinary(theEnv,constructBuffer,(unsigned long) CONSTRUCT_HEADER_SIZE))     {      intBool found;      /*==================================================*/      /* Search for the function to load the construct    */      /* into the previously allocated storage. If found, */      /* call the function to load the construct.         */      /*==================================================*/      found = FALSE;      for (biPtr = BsaveData(theEnv)->ListOfBinaryItems;           biPtr != NULL;           biPtr = biPtr->next)        {         if (strncmp(biPtr->name,constructBuffer,CONSTRUCT_HEADER_SIZE) == 0)           {            if (biPtr->bloadFunction != NULL)              {               (*biPtr->bloadFunction)(theEnv);               found = TRUE;              }            break;           }        }      /*==========================================*/      /* If the construct type wasn't found, skip */      /* the binary data for this construct.      */      /*==========================================*/      if (! found)        {         GenReadBinary(theEnv,&space,(unsigned long) sizeof(unsigned long));         GetSeekCurBinary(theEnv,(long) space);        }     }   /*=================*/   /* Close the file. */   /*=================*/   GenCloseBinary(theEnv);   /*========================================*/   /* Free up temporary storage used for the */   /* function and atomic value information. */   /*========================================*/   if (BloadData(theEnv)->FunctionArray != NULL)     {      genfree(theEnv,(void *) BloadData(theEnv)->FunctionArray,              sizeof(struct FunctionDefinition *) * numberOfFunctions);     }   FreeAtomicValueStorage(theEnv);   /*==================================*/   /* Call the list of functions to be */   /* executed after a bload occurs.   */   /*==================================*/   for (bfPtr = BloadData(theEnv)->AfterBloadFunctions;        bfPtr != NULL;        bfPtr = bfPtr->next)     {             if (bfPtr->environmentAware)        { (*bfPtr->func)(theEnv); }      else                    { (* (void (*)(void)) bfPtr->func)(); }     }   /*=======================================*/   /* Add a clear function to remove binary */   /* load when a clear command is issued.  */   /*=======================================*/   BloadData(theEnv)->BloadActive = TRUE;   EnvAddClearFunction(theEnv,"bload",(void (*)(void *)) ClearBload,10000);   /*=============================*/   /* Return TRUE to indicate the */   /* binary load was successful. */   /*=============================*/   return(TRUE);  }/************************************************************  NAME         : BloadandRefresh  DESCRIPTION  : Loads and refreshes objects - will bload                 all objects at once, if possible, but                 will aslo work in increments if memory is                 restricted  INPUTS       : 1) the number of objects to bload and update                 2) the size of one object                 3) An update function which takes a bloaded                    object buffer and the index of the object                    to refresh as arguments  RETURNS      : Nothing useful  SIDE EFFECTS : Objects bloaded and updated  NOTES        : Assumes binary file pointer is positioned                 for bloads of the objects ************************************************************/globle void BloadandRefresh(  void *theEnv,  long objcnt,  size_t objsz,  void (*objupdate)(void *,void *,long))  {   register long i,bi;   char *buf;   long objsmaxread,objsread;   size_t space;   int (*oldOutOfMemoryFunction)(void *,size_t);   if (objcnt == 0L) return;   oldOutOfMemoryFunction = EnvSetOutOfMemoryFunction(theEnv,BloadOutOfMemoryFunction);   objsmaxread = objcnt;   do     {      space = objsmaxread * objsz;      buf = (char *) genalloc(theEnv,space);      if (buf == NULL)        {         if ((objsmaxread / 2) == 0)           {            if ((*oldOutOfMemoryFunction)(theEnv,space) == TRUE)              {               EnvSetOutOfMemoryFunction(theEnv,oldOutOfMemoryFunction);               return;              }

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
欧美激情综合五月色丁香| 精油按摩中文字幕久久| 中文字幕国产一区二区| 国产色产综合色产在线视频| 精品1区2区在线观看| 精品奇米国产一区二区三区| 欧美成人三级电影在线| 精品国产一区二区三区不卡 | 色综合一个色综合| 99精品欧美一区二区三区小说| 懂色av噜噜一区二区三区av| 国产成a人亚洲精| 成人黄色软件下载| 99精品黄色片免费大全| 欧洲在线/亚洲| 在线电影一区二区三区| 日韩欧美二区三区| 欧美国产精品劲爆| 中文字幕字幕中文在线中不卡视频| 亚洲视频免费在线| 午夜国产精品一区| 狠狠久久亚洲欧美| 成人性色生活片免费看爆迷你毛片| av在线不卡电影| 欧美在线视频日韩| 日韩精品资源二区在线| 日本一区二区三区高清不卡| 中文字幕日韩一区| 亚洲国产视频直播| 麻豆成人av在线| 国产日韩欧美精品一区| 亚洲欧洲精品一区二区三区不卡| 夜夜嗨av一区二区三区网页| 青青草成人在线观看| 国产成人综合网| 欧美在线制服丝袜| 精品美女一区二区| 亚洲男人电影天堂| 美日韩一级片在线观看| 成人永久免费视频| 欧美日韩免费一区二区三区| 精品国产91久久久久久久妲己| 国产精品美女一区二区在线观看| 一区二区三区四区中文字幕| 蜜桃av一区二区| 91香蕉视频mp4| 欧美一级夜夜爽| 国产精品国产三级国产aⅴ中文 | 国产91清纯白嫩初高中在线观看| 91一区二区在线| 日韩欧美在线网站| 国产精品理论在线观看| 日本女人一区二区三区| eeuss鲁片一区二区三区 | 欧美成人三级电影在线| 综合在线观看色| 麻豆传媒一区二区三区| 色女孩综合影院| 久久久久久黄色| 亚洲国产一区二区在线播放| 国产精品69毛片高清亚洲| 欧美日韩免费一区二区三区 | 国产激情一区二区三区四区 | 日韩一区二区电影网| 国产精品成人免费精品自在线观看| 秋霞国产午夜精品免费视频| 91在线porny国产在线看| 精品国产伦一区二区三区免费| 亚洲一区av在线| 成人精品电影在线观看| 国产精品亚洲人在线观看| 欧美另类z0zxhd电影| 最新国产精品久久精品| 国产伦理精品不卡| 制服丝袜在线91| 伊人夜夜躁av伊人久久| 成年人午夜久久久| 久久尤物电影视频在线观看| 三级一区在线视频先锋| 91极品美女在线| 日韩美女久久久| 成人小视频在线观看| 久久久www成人免费无遮挡大片 | 欧美精品精品一区| 亚洲欧美成人一区二区三区| zzijzzij亚洲日本少妇熟睡| 久久久精品一品道一区| 国产一区二区三区在线观看免费| 日韩欧美综合一区| 日韩极品在线观看| 欧美日韩免费观看一区二区三区| 亚洲视频中文字幕| 不卡视频免费播放| 国产精品天天看| 国产成人精品综合在线观看| 337p粉嫩大胆噜噜噜噜噜91av| 久久精品国产99国产精品| 91麻豆精品国产自产在线观看一区| 亚洲综合区在线| 91黄色激情网站| 亚洲在线一区二区三区| 欧美性一级生活| 亚洲综合激情小说| 欧美日韩国产综合一区二区| 亚洲图片欧美综合| 9191久久久久久久久久久| 午夜在线成人av| 日韩欧美一级在线播放| 玖玖九九国产精品| 精品噜噜噜噜久久久久久久久试看| 麻豆成人91精品二区三区| 亚洲精品在线观看视频| 国产高清视频一区| 国产精品色噜噜| 一本大道久久a久久综合| 亚洲欧美另类久久久精品2019| 色狠狠av一区二区三区| 亚洲在线观看免费| 欧美高清视频一二三区| 麻豆传媒一区二区三区| 久久精品一区八戒影视| 成人黄色免费短视频| 一区二区久久久久久| 欧美日本在线看| 久久激情五月激情| 国产欧美视频一区二区| www.欧美精品一二区| 亚洲精品乱码久久久久久| 欧美精品自拍偷拍动漫精品| 国内精品久久久久影院薰衣草| 国产精品久久久久婷婷| 欧美在线一区二区| 久久av资源网| 亚洲特级片在线| 欧美一区二区三区免费在线看| 国产在线日韩欧美| 国产嫩草影院久久久久| 在线中文字幕不卡| 老汉av免费一区二区三区| 国产精品理伦片| 欧美日韩国产a| 国产精品123| 一区二区三区成人在线视频| 欧美电视剧在线观看完整版| 成人爱爱电影网址| 婷婷综合另类小说色区| 久久久久高清精品| 欧美在线高清视频| 国产麻豆精品视频| 午夜伊人狠狠久久| 亚洲国产精品精华液ab| 欧美精品一卡二卡| 成人性视频网站| 琪琪久久久久日韩精品| 亚洲人成小说网站色在线| 日韩精品专区在线影院观看| 91无套直看片红桃| 经典三级视频一区| 亚洲午夜精品一区二区三区他趣| 久久综合五月天婷婷伊人| 欧洲一区在线电影| 国产成人在线网站| 日韩在线观看一区二区| 国产精品久久久久久久岛一牛影视| 欧美丰满美乳xxx高潮www| 成人午夜私人影院| 免费成人结看片| 亚洲国产视频一区| 国产欧美1区2区3区| 制服丝袜av成人在线看| 一本到不卡免费一区二区| 国产精品综合在线视频| 天天亚洲美女在线视频| 亚洲欧洲精品一区二区三区| 久久一夜天堂av一区二区三区| 欧美精选午夜久久久乱码6080| 色综合欧美在线| 成人动漫av在线| 国内外成人在线| 日韩综合小视频| 亚洲最新视频在线观看| 国产精品免费看片| 久久精品日韩一区二区三区| 欧美一区二区三区爱爱| 欧美日韩一区二区三区高清| 91小宝寻花一区二区三区| 成人aa视频在线观看| 国产99久久久国产精品潘金| 精品一区二区av| 美女脱光内衣内裤视频久久网站| 亚洲国产精品尤物yw在线观看| 国产精品初高中害羞小美女文| 国产午夜精品一区二区三区四区 | 日韩精品视频网站| 一区二区久久久| 亚洲欧美日韩一区二区| 国产精品萝li| 国产精品色哟哟| 中文字幕第一区第二区| 中文字幕av在线一区二区三区|