~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to plugin/logging_stats/cumulative_stats.cc

  • Committer: Monty Taylor
  • Date: 2010-06-16 05:08:44 UTC
  • mfrom: (1616.2.2 fix_global_stats)
  • Revision ID: mordred@inaugust.com-20100616050844-q992zwwnjxl6u6tn
Merged Joe Daly from lp:~skinny.moey/drizzle/fix_global_stats

Show diffs side-by-side

added added

removed removed

Lines of Context:
141
141
  }
142
142
}
143
143
 
144
 
void CumulativeStats::sumCurrentScoreboardStatusVars(Scoreboard *scoreboard,
145
 
                                                     StatusVars *current_status_vars)
 
144
void CumulativeStats::sumCurrentScoreboard(Scoreboard *scoreboard,
 
145
                                           StatusVars *current_status_vars,
 
146
                                           UserCommands *current_user_commands)
146
147
{
147
148
  /* the vector of vectors */
148
149
  vector<vector<ScoreboardSlot* >* > *vector_of_scoreboard_vectors= 
165
166
      ScoreboardSlot *scoreboard_slot= *scoreboard_vector_it;
166
167
      if (scoreboard_slot->isInUse())
167
168
      {
168
 
        current_status_vars->merge(scoreboard_slot->getStatusVars());
 
169
        if (current_status_vars)
 
170
        {
 
171
          current_status_vars->merge(scoreboard_slot->getStatusVars());
 
172
        }
 
173
 
 
174
        if (current_user_commands)
 
175
        {
 
176
          current_user_commands->merge(scoreboard_slot->getUserCommands());
 
177
        }
169
178
      }
170
179
    }
171
180
  }