From 56106799548c1d94532c9083d9c085cf673278d9 Mon Sep 17 00:00:00 2001 From: Mark Linton Date: Tue, 9 Mar 1982 02:52:40 -0800 Subject: [PATCH] added a call to "initstart" so that process information is re-initialized SCCS-vsn: usr.bin/pascal/pdx/command/remake.c 1.2 --- usr/src/usr.bin/pascal/pdx/command/remake.c | 38 ++++++++++++--------- 1 file changed, 21 insertions(+), 17 deletions(-) diff --git a/usr/src/usr.bin/pascal/pdx/command/remake.c b/usr/src/usr.bin/pascal/pdx/command/remake.c index ff412c23e6..a1fd9d895e 100644 --- a/usr/src/usr.bin/pascal/pdx/command/remake.c +++ b/usr/src/usr.bin/pascal/pdx/command/remake.c @@ -1,6 +1,6 @@ /* Copyright (c) 1982 Regents of the University of California */ -static char sccsid[] = "@(#)remake.c 1.1 %G%"; +static char sccsid[] = "@(#)remake.c 1.2 %G%"; /* * Remake the object file from the source. @@ -15,26 +15,30 @@ static char sccsid[] = "@(#)remake.c 1.1 %G%"; * * We have to save tracing info before, and read it in after, because * it might contain symbol table pointers. + * + * We also have to restart the process so that px dependent information + * is recomputed. */ remake() { - char *tmpfile; + char *tmpfile; - if (call("pi", stdin, stdout, dotpfile, NIL) == 0) { - if (strcmp(objname, "obj") != 0) { - call("mv", stdin, stdout, "obj", objname, NIL); - } - tmpfile = mktemp("/tmp/pdxXXXX"); - setout(tmpfile); - status(); - unsetout(); - bpfree(); - objfree(); - readobj(objname); - setinput(tmpfile); - unlink(tmpfile); - } else { - puts("pi unsuccessful"); + if (call("pi", stdin, stdout, dotpfile, NIL) == 0) { + if (strcmp(objname, "obj") != 0) { + call("mv", stdin, stdout, "obj", objname, NIL); } + tmpfile = mktemp("/tmp/pdxXXXX"); + setout(tmpfile); + status(); + unsetout(); + bpfree(); + objfree(); + initstart(); + readobj(objname); + setinput(tmpfile); + unlink(tmpfile); + } else { + puts("pi unsuccessful"); + } } -- 2.20.1