ld -plugin options when plugins are disabled
[deliverable/binutils-gdb.git] / gdb / printcmd.c
index c94ad0a56005462b8a0969d6d230ee1dd276b869..388a0b2c6d414450f6c54c5f463d538167b29a9b 100644 (file)
@@ -2128,12 +2128,20 @@ clear_dangling_display_expressions (struct objfile *objfile)
       if (d->pspace != pspace)
        continue;
 
-      if (lookup_objfile_from_block (d->block) == objfile
+      struct objfile *bl_objf = nullptr;
+      if (d->block != nullptr)
+       {
+         bl_objf = block_objfile (d->block);
+         if (bl_objf->separate_debug_objfile_backlink != nullptr)
+           bl_objf = bl_objf->separate_debug_objfile_backlink;
+       }
+
+      if (bl_objf == objfile
          || (d->exp != NULL && exp_uses_objfile (d->exp.get (), objfile)))
-      {
-       d->exp.reset ();
-       d->block = NULL;
-      }
+       {
+         d->exp.reset ();
+         d->block = NULL;
+       }
     }
 }
 \f
This page took 0.023544 seconds and 4 git commands to generate.