summaryrefslogtreecommitdiffstats
path: root/logcat/logcat.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'logcat/logcat.cpp')
-rw-r--r--logcat/logcat.cpp10
1 files changed, 3 insertions, 7 deletions
diff --git a/logcat/logcat.cpp b/logcat/logcat.cpp
index db4fddd..16fe7ee 100644
--- a/logcat/logcat.cpp
+++ b/logcat/logcat.cpp
@@ -623,18 +623,14 @@ int main(int argc, char **argv)
}
if (!devices) {
- devices = new log_device_t("main", false, 'm');
+ dev = devices = new log_device_t("main", false, 'm');
android::g_devCount = 1;
if (android_name_to_log_id("system") == LOG_ID_SYSTEM) {
- devices->next = new log_device_t("system", false, 's');
+ dev = dev->next = new log_device_t("system", false, 's');
android::g_devCount++;
}
if (android_name_to_log_id("crash") == LOG_ID_CRASH) {
- if (devices->next) {
- devices->next->next = new log_device_t("crash", false, 'c');
- } else {
- devices->next = new log_device_t("crash", false, 'c');
- }
+ dev = dev->next = new log_device_t("crash", false, 'c');
android::g_devCount++;
}
}