summaryrefslogtreecommitdiffstats
path: root/lldb/source/lldb-log.cpp
diff options
context:
space:
mode:
authorGreg Clayton <gclayton@apple.com>2010-11-03 04:08:06 +0000
committerGreg Clayton <gclayton@apple.com>2010-11-03 04:08:06 +0000
commit6ba508507ed8fde28d1e811db34e693af5b5ab6f (patch)
tree097e293c3517c5aa54465793207299bf20776fea /lldb/source/lldb-log.cpp
parent2d5f8b420153625115244d910f2fe597f733eb22 (diff)
downloadbcm5719-llvm-6ba508507ed8fde28d1e811db34e693af5b5ab6f.tar.gz
bcm5719-llvm-6ba508507ed8fde28d1e811db34e693af5b5ab6f.zip
Fixed shared library unloads when the unloaded library doesn't come off
the end of the list. We had an issue in the MacOSX dynamic loader where if we had shlibs: 1 - a.out 2 - a.dylib 3 - b.dylib And then a.dylib got unloaded, we would unload b.dylib due to the assumption that only shared libraries could come off the end of the list. We now properly search and find which ones get loaded. Added a new internal logging category for the "lldb" log channel named "dyld". This should allow all dynamic loaders to use this as a generic log channel so we can track shared library loads and unloads in the logs without having to have each plug-in make up its own logging channel. llvm-svn: 118147
Diffstat (limited to 'lldb/source/lldb-log.cpp')
-rw-r--r--lldb/source/lldb-log.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/lldb/source/lldb-log.cpp b/lldb/source/lldb-log.cpp
index a7ba32801f1..dcda478281c 100644
--- a/lldb/source/lldb-log.cpp
+++ b/lldb/source/lldb-log.cpp
@@ -124,6 +124,7 @@ lldb_private::DisableLog (Args &args, Stream *feedback_strm)
else if (strcasecmp(arg, "api") == 0) flag_bits &= ~LIBLLDB_LOG_API;
else if (strcasestr(arg, "break") == arg) flag_bits &= ~LIBLLDB_LOG_BREAKPOINTS;
else if (strcasecmp(arg, "default") == 0 ) flag_bits &= ~LIBLLDB_LOG_DEFAULT;
+ else if (strcasecmp(arg, "dyld") == 0 ) flag_bits &= ~LIBLLDB_LOG_DYNAMIC_LOADER;
else if (strcasestr(arg, "event") == arg) flag_bits &= ~LIBLLDB_LOG_EVENTS;
else if (strcasestr(arg, "expr") == arg) flag_bits &= ~LIBLLDB_LOG_EXPRESSIONS;
else if (strcasestr(arg, "object") == arg) flag_bits &= ~LIBLLDB_LOG_OBJECT;
@@ -182,6 +183,7 @@ lldb_private::EnableLog (StreamSP &log_stream_sp, uint32_t log_options, Args &ar
else if (strcasecmp(arg, "api") == 0) flag_bits |= LIBLLDB_LOG_API;
else if (strcasestr(arg, "break") == arg) flag_bits |= LIBLLDB_LOG_BREAKPOINTS;
else if (strcasecmp(arg, "default") == 0 ) flag_bits |= LIBLLDB_LOG_DEFAULT;
+ else if (strcasecmp(arg, "dyld") == 0 ) flag_bits |= LIBLLDB_LOG_DYNAMIC_LOADER;
else if (strcasestr(arg, "event") == arg) flag_bits |= LIBLLDB_LOG_EVENTS;
else if (strcasestr(arg, "expr") == arg) flag_bits |= LIBLLDB_LOG_EXPRESSIONS;
else if (strcasestr(arg, "object") == arg) flag_bits |= LIBLLDB_LOG_OBJECT;
OpenPOWER on IntegriCloud