Index: /trunk/Mars/hawc/callisto.C
===================================================================
--- /trunk/Mars/hawc/callisto.C	(revision 19703)
+++ /trunk/Mars/hawc/callisto.C	(revision 19704)
@@ -35,7 +35,11 @@
 ******************************************************************/
 int callisto(const char *datafile, const char *drsfile,
-             const char *drstime=0, const char *delays=0,
              const char *outpath=".")
 {
+    // ======================================================
+
+    const char *drstime = 0;
+    const char *delays  = 0;
+
     // ======================================================
 
@@ -276,7 +280,10 @@
     // Convert the name of the input file to the name of the output file
     TString fname = gSystem->ConcatFileName(outpath, gSystem->BaseName(datafile));
-    fname.ReplaceAll(".fits.gz", "_C.root");
-    fname.ReplaceAll(".fits.fz", "_C.root");
-    fname.ReplaceAll(".fits",    "_C.root");
+    fname.ReplaceAll(".fits.gz", ".root");
+    fname.ReplaceAll(".fits.fz", ".root");
+    fname.ReplaceAll(".fits",    ".root");
+    fname.ReplaceAll("_D_",      "_C_");
+
+    gSystem->ExpandPathName(fname);
 
     // Instantitate the writing task and setup the writing
@@ -335,4 +342,5 @@
     // Check if the output file is still accessible from root
     TFile *ofile = (TFile*)gROOT->GetListOfFiles()->FindObject(fname);
+    cout << ofile << endl;
     if (!ofile || !ofile->IsOpen() || ofile->IsZombie())
     {
