Esempio n. 1
0
genfile agt_globalfile(int fid)
{
  if (fid==0) 
    return badfile(fCFG); /* Should return FILE* to open
			      global configuration file */
  else return badfile(fCFG);
}
Esempio n. 2
0
File: spew.c Progetto: pstef/cq410z
void instring(register char *where, register int how_many)
{
  register int c;

  do {
    c = getc(InFile);
    if (c == EOF)
      badfile();
    *where++ = c;
    if (c == '\0')
      return;
  } while (--how_many);
  badfile();
}
Esempio n. 3
0
File: spew.c Progetto: pstef/cq410z
void readcclass(register classrec *cp)
{
  register int n;
  register defn *dp;
  defn **dput;

  char store[MAXDEF]; /* for tags */

  cp->weight = getw(InFile);
  instring(store, MAXDEF);
  cp->tags = (store[0] == '\0') ? NullTags : save(store);
  n = getw(InFile);
  if (n <= 0)
    badfile();
  dput = &(cp->list); /* link on here */
  while (n--) {
    dp = (defn *)my_alloc((unsigned) sizeof(defn));
    *dput = dp;
    dp->cumul = getw(InFile);
    instring(store, MAXDEF);
    dp->string = save(store);
    dput = &(dp->next);
  }
  *dput = NULL; /* last one */
}
Esempio n. 4
0
void init_interface(int argc,char *argv[])
{
  script_on=0;scriptfile=badfile(fSCR);
  scroll_count=0;
  center_on=par_fill_on=0;
  debugfile=stderr;
  DEBUG_OUT=0; /* If set, we echo all output to debugfile */
       /* This should be 1 if stderr points to a different */
       /* device than stdin. (E.g. to a file instead of to the */
       /* console) */
  screen_height=25;  /* Assume PC dimensions */
  status_width=screen_width=80;
  agt_clrscr();
}