aboutsummaryrefslogtreecommitdiff
path: root/src/graph/viewAlone/spoon2D.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/graph/viewAlone/spoon2D.c')
-rw-r--r--src/graph/viewAlone/spoon2D.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/src/graph/viewAlone/spoon2D.c b/src/graph/viewAlone/spoon2D.c
index 00f46e31..912d834b 100644
--- a/src/graph/viewAlone/spoon2D.c
+++ b/src/graph/viewAlone/spoon2D.c
@@ -58,7 +58,7 @@ spoonView2D(void)
{
int i,code,pipe0[2],pipe1[2],there;
- char envAXIOM[100],runView[100];
+ char runView[100];
sprintf(errorStr,"%s","creating pipes");
check(pipe(pipe0));
@@ -84,8 +84,7 @@ spoonView2D(void)
close(pipe1[1]);
printf("(spoon2D child) start the TwoDimensionalViewport process\n");
sprintf(errorStr,"%s","(viewAlone) execution of the TwoDimensionalViewport process");
- sprintf(envAXIOM,"%s",oa_getenv("AXIOM"));
- sprintf(runView,"%s%s",envAXIOM,"/lib/view2D");
+ sprintf(runView,"%s/lib/view2D",oa_getenv("AXIOM"));
check(execl(runView,runView, (char*)NULL));
fprintf(stderr,"Could not execute view2D! Check that view2D is on your path variable.\n");
exit(-1);
@@ -215,7 +214,7 @@ makeView2DFromFileData(view2DStruct *doView2D)
int i,j,k;
char title[256];
FILE *graphFile;
- char graphFilename[256];
+ char graphFilename[512];
pointListStruct *aList;
pointStruct *aPoint;
printf("(spoon2D makeView2DFromFileData)\n");
@@ -280,7 +279,7 @@ makeView2DFromFileData(view2DStruct *doView2D)
for (i=0; i<maxGraphs; i++) {
if (graphArray[i].key) {
/** OPEN FILE FOR GRAPHS **/
- sprintf(graphFilename,"%s%s%d",pathname,"/graph",i);
+ sprintf(graphFilename,"%s/graph%d",pathname,i);
if ((graphFile = fopen(graphFilename,"r")) == NULL) {
fprintf(stderr," Error: Cannot find the file %s\n",graphFilename);
perror("fopen");