plan9port

fork of plan9port with libvec, libstr and libsdb
Log | Files | Refs | README | LICENSE

get9root.c (171B)


      1 #include <u.h>
      2 #include <libc.h>
      3 
      4 char*
      5 get9root(void)
      6 {
      7 	static char *s;
      8 
      9 	if(s)
     10 		return s;
     11 
     12 	if((s = getenv("PLAN9")) != 0)
     13 		return s;
     14 	s = PLAN9_TARGET;
     15 	return s;
     16 }