aboutsummaryrefslogtreecommitdiffstats
path: root/traceview/src
diff options
context:
space:
mode:
authorSiva Velusamy <vsiva@google.com>2012-07-31 13:02:49 -0700
committerSiva Velusamy <vsiva@google.com>2012-07-31 14:16:10 -0700
commit6e9b3ca6d201a7eaddeaba2ef23cbf601eb226b6 (patch)
tree2540e9384eebd62d5b92e85c3e7f30b1350ad3f1 /traceview/src
parent6a2d4d7796030c038ed0a59f1a68ae4d2108209f (diff)
downloadsdk-6e9b3ca6d201a7eaddeaba2ef23cbf601eb226b6.zip
sdk-6e9b3ca6d201a7eaddeaba2ef23cbf601eb226b6.tar.gz
sdk-6e9b3ca6d201a7eaddeaba2ef23cbf601eb226b6.tar.bz2
traceview: It is a context switch only if id == -1
Currently, method id's are assumed to be positive integer values, with a context switch receiving the special id -1. However, it is possible that id's > 0x8000_0000 are generated, in which case they are represented as negative integers. This patch simply fixes the check for whether an id denotes a context switch to be (id == -1) rather than (id < 0). Change-Id: I75ada085f875d8c6bdc54c6f132ba4600633a062
Diffstat (limited to 'traceview/src')
-rw-r--r--traceview/src/com/android/traceview/Call.java2
1 files changed, 1 insertions, 1 deletions
diff --git a/traceview/src/com/android/traceview/Call.java b/traceview/src/com/android/traceview/Call.java
index f786805..0330b05 100644
--- a/traceview/src/com/android/traceview/Call.java
+++ b/traceview/src/com/android/traceview/Call.java
@@ -118,7 +118,7 @@ class Call implements TimeLineView.Block {
@Override
public boolean isContextSwitch() {
- return mMethodData.getId() < 0;
+ return mMethodData.getId() == -1;
}
@Override