~ubuntu-branches/ubuntu/trusty/nordugrid-arc/trusty

« back to all changes in this revision

Viewing changes to src/clients/compute/arcrenew.cpp

  • Committer: Package Import Robot
  • Author(s): Mattias Ellert
  • Date: 2013-11-29 13:39:10 UTC
  • mfrom: (3.1.16 sid)
  • Revision ID: package-import@ubuntu.com-20131129133910-sy6ayoavphc5hozs
Tags: 4.0.0-1
4.0.0 Release (Closes: #715131) (LP: #1049798)

Show diffs side-by-side

added added

removed removed

Lines of Context:
87
87
  std::list<std::string> rejectManagementURLs = getRejectManagementURLsFromUserConfigAndCommandLine(usercfg, opt.rejectmanagement);
88
88
 
89
89
  std::list<Arc::Job> jobs;
90
 
  Arc::JobInformationStorageXML jobList(usercfg.JobListFile());
91
 
  if (( opt.all && !jobList.ReadAll(jobs, rejectManagementURLs)) ||
92
 
      (!opt.all && !jobList.Read(jobs, jobidentifiers, selectedURLs, rejectManagementURLs))) {
 
90
  Arc::JobInformationStorage *jobstore = createJobInformationStorage(usercfg);
 
91
  if (jobstore != NULL && !jobstore->IsStorageExisting()) {
 
92
    logger.msg(Arc::ERROR, "Job list file (%s) doesn't exist", usercfg.JobListFile());
 
93
    delete jobstore;
 
94
    return 1;
 
95
  }
 
96
  if (jobstore == NULL ||
 
97
      ( opt.all && !jobstore->ReadAll(jobs, rejectManagementURLs)) ||
 
98
      (!opt.all && !jobstore->Read(jobs, jobidentifiers, selectedURLs, rejectManagementURLs))) {
93
99
    logger.msg(Arc::ERROR, "Unable to read job information from file (%s)", usercfg.JobListFile());
 
100
    delete jobstore;
94
101
    return 1;
95
102
  }
 
103
  delete jobstore;
96
104
 
97
105
  if (!opt.all) {
98
106
    for (std::list<std::string>::const_iterator itJIDAndName = jobidentifiers.begin();