summaryrefslogtreecommitdiff
path: root/lib/CodeGen/SelectionDAG/SelectionDAGPrinter.cpp
diff options
context:
space:
mode:
authorTed Kremenek <kremenek@apple.com>2008-10-27 22:43:07 +0000
committerTed Kremenek <kremenek@apple.com>2008-10-27 22:43:07 +0000
commit8e7fa916fe87733b3660466b3a1c91d650c473d3 (patch)
treeec3008eda611d84b56fa63a36ad9b23eccb1b882 /lib/CodeGen/SelectionDAG/SelectionDAGPrinter.cpp
parent8ad4c00c00233acb8a3395098e2b575cc34de46b (diff)
downloadllvm-8e7fa916fe87733b3660466b3a1c91d650c473d3.tar.gz
llvm-8e7fa916fe87733b3660466b3a1c91d650c473d3.tar.bz2
llvm-8e7fa916fe87733b3660466b3a1c91d650c473d3.tar.xz
Fix bogus comparison of "const char *" with c-string literal. Use strcmp instead.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@58290 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/SelectionDAG/SelectionDAGPrinter.cpp')
-rw-r--r--lib/CodeGen/SelectionDAG/SelectionDAGPrinter.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/CodeGen/SelectionDAG/SelectionDAGPrinter.cpp b/lib/CodeGen/SelectionDAG/SelectionDAGPrinter.cpp
index 6decc00f40..9cca672046 100644
--- a/lib/CodeGen/SelectionDAG/SelectionDAGPrinter.cpp
+++ b/lib/CodeGen/SelectionDAG/SelectionDAGPrinter.cpp
@@ -369,10 +369,10 @@ void SelectionDAG::setSubgraphColor(SDNode *N, const char *Color) {
bool printed = false;
if (setSubgraphColorHelper(N, Color, visited, 0, printed)) {
// Visually mark that we hit the limit
- if (Color == "red" ) {
+ if (strcmp(Color, "red") == 0) {
setSubgraphColorHelper(N, "blue", visited, 0, printed);
}
- else if (Color == "yellow" ) {
+ else if (strcmp(Color, "yellow") == 0) {
setSubgraphColorHelper(N, "green", visited, 0, printed);
}
}