llvm.org GIT mirror llvm / c8fccc5
Merging r300267: ------------------------------------------------------------------------ r300267 | tejohnson | 2017-04-13 17:51:49 -0400 (Thu, 13 Apr 2017) | 11 lines [Support] Fix ErrorOr assertion when /proc/cpuinfo doesn't exist. The ErrorOr should not be dereferenced on the error path. Patch by Jacob Young Reviewers: tejohnson Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D32032 ------------------------------------------------------------------------ git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_40@305264 91177308-0d34-0410-b5e6-96231b3b80d8 Tom Stellard 2 years ago
1 changed file(s) with 1 addition(s) and 0 deletion(s). Raw diff Collapse all Expand all
12311231 if (std::error_code EC = Text.getError()) {
12321232 llvm::errs() << "Can't read "
12331233 << "/proc/cpuinfo: " << EC.message() << "\n";
1234 return -1;
12341235 }
12351236 SmallVector strs;
12361237 (*Text)->getBuffer().split(strs, "\n", /*MaxSplit=*/-1,