]> sourceware.org Git - systemtap.git/commitdiff
Suppress module-loading errors in @casts
authorJosh Stone <jistone@redhat.com>
Mon, 20 Apr 2009 23:43:15 +0000 (16:43 -0700)
committerJosh Stone <jistone@redhat.com>
Mon, 20 Apr 2009 23:43:15 +0000 (16:43 -0700)
If a @cast encounters a module that it can't load, it should just go on
to the next module instead of throwing an exception.  If there is no
next module, we'll get a better "type not found" exception anyway.

tapsets.cxx

index 01c838d930d768214cf4228a097654e6deb3b368..ee799e748a99a1334d7ebdb48f4b9728aa52523c 100644 (file)
@@ -5148,7 +5148,16 @@ void dwarf_cast_expanding_visitor::visit_cast_op (cast_op* e)
           if (db.user_dw.find(module) == db.user_dw.end())
             {
               dw = new dwflpp(s);
-              dw->setup_user(module);
+              try
+                {
+                  dw->setup_user(module);
+                }
+              catch (const semantic_error& er)
+                {
+                  /* ignore and go to the next module */
+                  delete dw;
+                  continue;
+                }
               db.user_dw[module] = dw;
             }
           else
This page took 0.034438 seconds and 5 git commands to generate.