Skip to content
Snippets Groups Projects

Better memory management and float rounding issues

Merged Ghost User requested to merge issue12 into master
3 files
+ 23
4
Compare changes
  • Side-by-side
  • Inline
Files
3
@@ -152,8 +152,14 @@ void DynScheduler::submit_broker_jobs(double date)
std::list<Profile *> profiles;
broker->jobs_to_submit(date, jobs, profiles);
if (!profiles.empty())
if (!profiles.empty()) {
dyn_register_profiles(profiles, date);
/* Profiles won't be used anymore, free memory */
for (const Profile *profile : profiles){
delete profile;
}
}
dyn_submit(jobs, date);
}
@@ -165,7 +171,7 @@ void DynScheduler::dyn_submit(std::list<Job *> jobs, double date)
{
std::string fullID = current_job->id;
PPK_ASSERT_ERROR(fullID.find('!') != std::string::npos,
"Dynamicaly submitted jobs should have the format "
"Dynamically submitted jobs should have the format "
"'user_name!jobID'.");
std::string user_name = fullID.substr(0, fullID.find('!'));
fullID.erase(0, fullID.find('!') + 1);
Loading