Files
9base/lib9/get9root.c
2009-08-25 20:05:27 +01:00

19 lines
204 B
C

#include <u.h>
#include <libc.h>
char*
get9root(void)
{
static char *s;
if(s)
return s;
if((s = getenv("PLAN9")) != 0)
return s;
/* could do better - search $PATH */
s = PREFIX;
return s;
}