Check that there is a param context list before trying
to loop through it. This is more important as we get rid of param contexts --HG-- extra : convert_revision : 5a24048b5c3d609285da83dfcb106910afad6919
This commit is contained in:
parent
a41f17b40e
commit
01f32efa4b
1 changed files with 15 additions and 7 deletions
|
@ -701,11 +701,12 @@ ParamContext::printErrorProlog(ostream &os)
|
||||||
void
|
void
|
||||||
ParamContext::parseAllContexts(IniFile &iniFile)
|
ParamContext::parseAllContexts(IniFile &iniFile)
|
||||||
{
|
{
|
||||||
list<ParamContext *>::iterator iter;
|
if (!ctxList)
|
||||||
|
return;
|
||||||
|
|
||||||
|
list<ParamContext *>::iterator iter;
|
||||||
for (iter = ctxList->begin(); iter != ctxList->end(); ++iter) {
|
for (iter = ctxList->begin(); iter != ctxList->end(); ++iter) {
|
||||||
ParamContext *pc = *iter;
|
ParamContext *pc = *iter;
|
||||||
|
|
||||||
pc->parseParams(iniFile);
|
pc->parseParams(iniFile);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -717,11 +718,12 @@ ParamContext::parseAllContexts(IniFile &iniFile)
|
||||||
void
|
void
|
||||||
ParamContext::checkAllContexts()
|
ParamContext::checkAllContexts()
|
||||||
{
|
{
|
||||||
list<ParamContext *>::iterator iter;
|
if (!ctxList)
|
||||||
|
return;
|
||||||
|
|
||||||
|
list<ParamContext *>::iterator iter;
|
||||||
for (iter = ctxList->begin(); iter != ctxList->end(); ++iter) {
|
for (iter = ctxList->begin(); iter != ctxList->end(); ++iter) {
|
||||||
ParamContext *pc = *iter;
|
ParamContext *pc = *iter;
|
||||||
|
|
||||||
pc->checkParams();
|
pc->checkParams();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -733,8 +735,10 @@ ParamContext::checkAllContexts()
|
||||||
void
|
void
|
||||||
ParamContext::showAllContexts(ostream &os)
|
ParamContext::showAllContexts(ostream &os)
|
||||||
{
|
{
|
||||||
list<ParamContext *>::iterator iter;
|
if (!ctxList)
|
||||||
|
return;
|
||||||
|
|
||||||
|
list<ParamContext *>::iterator iter;
|
||||||
for (iter = ctxList->begin(); iter != ctxList->end(); ++iter) {
|
for (iter = ctxList->begin(); iter != ctxList->end(); ++iter) {
|
||||||
ParamContext *pc = *iter;
|
ParamContext *pc = *iter;
|
||||||
|
|
||||||
|
@ -751,8 +755,10 @@ ParamContext::showAllContexts(ostream &os)
|
||||||
void
|
void
|
||||||
ParamContext::cleanupAllContexts()
|
ParamContext::cleanupAllContexts()
|
||||||
{
|
{
|
||||||
list<ParamContext *>::iterator iter;
|
if (!ctxList)
|
||||||
|
return;
|
||||||
|
|
||||||
|
list<ParamContext *>::iterator iter;
|
||||||
for (iter = ctxList->begin(); iter != ctxList->end(); ++iter) {
|
for (iter = ctxList->begin(); iter != ctxList->end(); ++iter) {
|
||||||
ParamContext *pc = *iter;
|
ParamContext *pc = *iter;
|
||||||
|
|
||||||
|
@ -767,8 +773,10 @@ ParamContext::cleanupAllContexts()
|
||||||
void
|
void
|
||||||
ParamContext::describeAllContexts(ostream &os)
|
ParamContext::describeAllContexts(ostream &os)
|
||||||
{
|
{
|
||||||
list<ParamContext *>::iterator iter;
|
if (!ctxList)
|
||||||
|
return;
|
||||||
|
|
||||||
|
list<ParamContext *>::iterator iter;
|
||||||
for (iter = ctxList->begin(); iter != ctxList->end(); ++iter) {
|
for (iter = ctxList->begin(); iter != ctxList->end(); ++iter) {
|
||||||
ParamContext *pc = *iter;
|
ParamContext *pc = *iter;
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue