X-Git-Url: http://demsky.eecs.uci.edu/git/?a=blobdiff_plain;f=lib%2FOption%2FOption.cpp;h=f1b7941e498293b6b30e679839f5f3b5a17359cd;hb=11eb51e23935e22e1cb7b346c45713e8c9169c84;hp=0e2263475e0cad1c84b21b56e71f97472f230830;hpb=58a2cbef4aac9ee7d530dfb690c78d6fc11a2371;p=oota-llvm.git diff --git a/lib/Option/Option.cpp b/lib/Option/Option.cpp index 0e2263475e0..f1b7941e498 100644 --- a/lib/Option/Option.cpp +++ b/lib/Option/Option.cpp @@ -50,11 +50,13 @@ void Option::dump() const { #undef P } - llvm::errs() << " Prefixes:["; - for (const char * const *Pre = Info->Prefixes; *Pre != 0; ++Pre) { - llvm::errs() << '"' << *Pre << (*(Pre + 1) == 0 ? "\"" : "\", "); + if (Info->Prefixes) { + llvm::errs() << " Prefixes:["; + for (const char * const *Pre = Info->Prefixes; *Pre != 0; ++Pre) { + llvm::errs() << '"' << *Pre << (*(Pre + 1) == 0 ? "\"" : "\", "); + } + llvm::errs() << ']'; } - llvm::errs() << ']'; llvm::errs() << " Name:\"" << getName() << '"';