home *** CD-ROM | disk | FTP | other *** search
/ Gold Fish 3 / goldfish_volume_3.bin / files / gfx / 3d / irit / amigalib / putenv.c < prev    next >
Encoding:
C/C++ Source or Header  |  1995-02-26  |  229 b   |  18 lines

  1. #include <string.h>
  2. #include <proto/dos.h>
  3.  
  4. int
  5. putenv(char *s)
  6. {
  7.   char *delim;
  8.  
  9.   delim = strchr(s, '=');
  10.   if (!delim) {
  11.     return 1;
  12.   }
  13.   *delim = 0;
  14.   SetVar(s, delim+1, -1, GVF_GLOBAL_ONLY);
  15.   *delim = '=';
  16.   return 0;
  17. }
  18.