diff options
Diffstat (limited to 'src/cmd/grap')
-rw-r--r-- | src/cmd/grap/main.c | 2 | ||||
-rw-r--r-- | src/cmd/grap/print.c | 6 |
2 files changed, 5 insertions, 3 deletions
diff --git a/src/cmd/grap/main.c b/src/cmd/grap/main.c index ea0309d4..07f4ecad 100644 --- a/src/cmd/grap/main.c +++ b/src/cmd/grap/main.c @@ -10,7 +10,7 @@ int dbg = 0; #ifndef GRAPDEFINES -#define GRAPDEFINES "#9/sys/lib/grap.defines" +#define GRAPDEFINES "#9/lib/grap.defines" #endif char *lib_defines; diff --git a/src/cmd/grap/print.c b/src/cmd/grap/print.c index 1636ec21..4598cb81 100644 --- a/src/cmd/grap/print.c +++ b/src/cmd/grap/print.c @@ -177,6 +177,7 @@ void do_first(void) /* done at first .G1: definitions, etc. */ { extern int lib; extern char *lib_defines; + char *file; static char buf[50], buf1[50]; /* static because pbstr uses them */ FILE *fp; extern int getpid(void); @@ -184,8 +185,9 @@ void do_first(void) /* done at first .G1: definitions, etc. */ sprintf(buf, "define pid /%d/\n", getpid()); pbstr(buf); if (lib != 0) { - if ((fp = fopen(unsharp(lib_defines), "r")) != NULL) { - sprintf(buf1, "copy \"%s\"\n", lib_defines); + file = unsharp(lib_defines); + if ((fp = fopen(file, "r")) != NULL) { + sprintf(buf1, "copy \"%s\"\n", file); pbstr(buf1); fclose(fp); } else { |