Commit 3defa2817417b4268ee7febd70e9f9e6a756c08f

  • avatar
  • con <qtc-committer @no…a.com> (Committer)
  • Thu Nov 26 16:38:57 CET 2009
  • avatar
  • Thorbjørn Lindeijer (Author)
  • Thu Nov 26 16:22:03 CET 2009
Fixed possible crash in the code completion

Null pointer reference in a case where the global namespace is
explicitly specified using ::

Task-number: QTCREATORBUG-351
Review-pending-by: Roberto Raggi
(cherry picked from commit b02d705ac4f4fb256c3d92340720e4fb972ba0f9)
  
513513 q->isGlobal());
514514 const QList<Symbol *> candidates = resolveClassOrNamespace(nestedNameSpec, visibleScopes);
515515 for (int j = 0; j < candidates.size(); ++j) {
516 expand(candidates.at(j)->asScopedSymbol()->members(),
517 visibleScopes, expandedScopes);
516 if (ScopedSymbol *scopedSymbol = candidates.at(j)->asScopedSymbol())
517 expand(scopedSymbol->members(), visibleScopes, expandedScopes);
518518 }
519519 }
520520}