File: porting.c

package info (click to toggle)
ucbmpeg 1r2-6
  • links: PTS
  • area: non-free
  • in suites: hamm, potato, slink
  • size: 9,504 kB
  • ctags: 7,643
  • sloc: ansic: 79,920; tcl: 2,985; perl: 313; asm: 284; makefile: 269; csh: 13
file content (24 lines) | stat: -rw-r--r-- 405 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
/*
   If you do not have isprint(c)   (sequent) 
   Add the following line to video.c
*/
#define isprint(x) (x>=' ')


/*
  If you do not have strdup   (some DECs)
  Add the following to main.c
*/
#define NULL 0
char * strdup(x) 
char *x;
{
  char *new;
  new= (char *) malloc(strlen(x));
  if (new == NULL) {
    printf("Unable to allocate string!\n");
    exit(1);
  }
  strcpy(new, x);
  return new;
}