diff options
Diffstat (limited to 'src/Startup.c')
-rw-r--r-- | src/Startup.c | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/src/Startup.c b/src/Startup.c index 50b82ea..d7406c0 100644 --- a/src/Startup.c +++ b/src/Startup.c @@ -118,7 +118,7 @@ static void *IOJpeg_SetupGH (tFleshConfig *config, int conv_level, cGH *GH) CCTK_RegisterIOMethodTimeToOutput (i, IOJpeg_TimeFor); CCTK_RegisterIOMethodTriggerOutput (i, IOJpeg_TriggerOutput); - if (! CCTK_Equals (newverbose, "none")) + if (! CCTK_Equals (verbose, "none")) { CCTK_INFO ("I/O Method 'IOJpeg' registered"); CCTK_INFO ("IOJpeg: Output of 2D jpeg images of grid functions/arrays"); @@ -136,36 +136,36 @@ static void *IOJpeg_SetupGH (tFleshConfig *config, int conv_level, cGH *GH) myGH->out_vars = strdup (""); myGH->out_every_default = out_every - 1; - /* Check whether "out2D_dir" was set. - If so take this dir otherwise default to "IO::outdir" */ - if (*out2D_dir == 0) + /* get the name for IOJpeg's output directory */ + if (*out_dir == 0) { - out2D_dir = outdir; + out_dir = *(const char **) + CCTK_ParameterGet ("out_dir", CCTK_ImplementationThorn ("IO"), NULL); } /* omit the directory if it's the current working dir */ - if (strcmp (out2D_dir, ".") == 0) + if (strcmp (out_dir, ".") == 0) { - myGH->outdir = strdup (""); + myGH->out_dir = strdup (""); } else { - myGH->outdir = (char *) malloc (strlen (out2D_dir) + 2); - sprintf (myGH->outdir, "%s/", out2D_dir); + myGH->out_dir = (char *) malloc (strlen (out_dir) + 2); + sprintf (myGH->out_dir, "%s/", out_dir); } /* create the output dir */ - i = IOUtil_CreateDirectory (GH, myGH->outdir, 0, 0); + i = IOUtil_CreateDirectory (GH, myGH->out_dir, 0, 0); if (i < 0) { CCTK_VWarn (1, __LINE__, __FILE__, CCTK_THORNSTRING, "IOJpeg_SetupGH: problem creating IOJpeg output directory '%s'", - myGH->outdir); + myGH->out_dir); } - else if (i >= 0 && CCTK_Equals (newverbose, "full")) + else if (i >= 0 && CCTK_Equals (verbose, "full")) { CCTK_VInfo (CCTK_THORNSTRING, "IOJpeg: Output to directory '%s'", - myGH->outdir); + myGH->out_dir); } return (myGH); |