bug-binutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Bug gold/17128] internal error in lock, at ../../binutils/gold/fileread


From: ccoutant at google dot com
Subject: [Bug gold/17128] internal error in lock, at ../../binutils/gold/fileread.cc:295
Date: Wed, 09 Jul 2014 18:56:18 +0000

https://sourceware.org/bugzilla/show_bug.cgi?id=17128

Cary Coutant <ccoutant at google dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|---                         |INVALID

--- Comment #1 from Cary Coutant <ccoutant at google dot com> ---
You need to call the release_input_file API when you're done with each file.

It works fine with this patch:

--- plugin.cpp    2014-07-08 08:24:35.000000000 -0700
+++ plugin2.cpp    2014-07-09 11:51:57.000000000 -0700
@@ -3,6 +3,7 @@
 #include <vector>

 static ld_plugin_get_input_file get_input_file = nullptr;
+static ld_plugin_release_input_file release_input_file = nullptr;
 static std::vector<void *> Modules;

 static ld_plugin_status claim_file_hook(const ld_plugin_input_file *file,
@@ -16,6 +17,7 @@ static ld_plugin_status all_symbols_read
   for (auto &I : Modules) {
     ld_plugin_input_file File;
     get_input_file(I, &File);
+    release_input_file(I);
   }
   return LDPS_OK;
 }
@@ -39,6 +41,10 @@ extern "C" ld_plugin_status onload(ld_pl
       get_input_file = tv->tv_u.tv_get_input_file;
       break;

+    case LDPT_RELEASE_INPUT_FILE:
+      release_input_file = tv->tv_u.tv_release_input_file;
+      break;
+
       break;
     default:
       break;

-- 
You are receiving this mail because:
You are on the CC list for the bug.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]