Back To Overview
SP3EphemerisStore.loadFile does not throw FileMis
Posted on 17 Feb, 2012 by AlainMuls
Hi

I started to look at the ppp example and while reworking it to use it with a configuration file, I noticed that SP3EphemerisStore.loadFile does not throw FileMissingException while deliberately misspelling the name of the precise ephemeris files (read by peOption).

using
      if (access(peOption.getValue()[i].c_str(),R_OK) == 0)
      {
       sp3Store.loadFile(peOption.getValue()[i].c_str());
      }
      else
      {
        printf("%s: %s\n",peOption.getValue()[i].c_str(),strerror(errno));
        exit(E_FILENOTEXIST);
      }

I get the error message E_FILENOTEXIST

But if I use the code from the example:
      while ( (sp3File = confReader.fetchListValue("SP3List",station) ) != "" )
      {

            // Try to load each ephemeris file
         try
         {

            SP3EphList.loadFile( sp3File );

         }
         catch (FileMissingException& e)
         {
               // If file doesn't exist, issue a warning
            cerr << "SP3 file '" << sp3File << "' doesn't exist or you don't "
                 << "have permission to read it. Skipping it." << endl;

            continue;
         }
    }

No warning message is being printed to stderr. Anyone has encountered the same problem, and what is the solution?

Add your comments to the Discussion
 



Topic revision: r1 - 17 Feb 2012, AlainMuls
 

This site is powered by FoswikiCopyright © by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding Foswiki? Send feedback