From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.devel Subject: Re: Dynamic loading progress Date: Thu, 03 Jul 2014 21:26:35 -0400 Message-ID: References: NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1404437223 27298 80.91.229.3 (4 Jul 2014 01:27:03 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 4 Jul 2014 01:27:03 +0000 (UTC) Cc: Emacs development discussions To: =?windows-1252?Q?Aur=E9lien?= Aptel Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Fri Jul 04 03:26:56 2014 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1X2sH9-00054Y-Vv for ged-emacs-devel@m.gmane.org; Fri, 04 Jul 2014 03:26:56 +0200 Original-Received: from localhost ([::1]:34103 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1X2sH9-0002Md-0j for ged-emacs-devel@m.gmane.org; Thu, 03 Jul 2014 21:26:55 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:59967) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1X2sGy-0002MG-T0 for emacs-devel@gnu.org; Thu, 03 Jul 2014 21:26:52 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1X2sGq-0001HC-Vh for emacs-devel@gnu.org; Thu, 03 Jul 2014 21:26:44 -0400 Original-Received: from ironport2-out.teksavvy.com ([206.248.154.181]:11588) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1X2sGq-0001H3-R4 for emacs-devel@gnu.org; Thu, 03 Jul 2014 21:26:36 -0400 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: ArUGAIDvNVNLd+D9/2dsb2JhbABZgwaDSsA9gRcXdIIlAQEBAQIBViMFCws0EhQYDSSIBAjSGReOegeEOASpGYFqg0wh X-IPAS-Result: ArUGAIDvNVNLd+D9/2dsb2JhbABZgwaDSsA9gRcXdIIlAQEBAQIBViMFCws0EhQYDSSIBAjSGReOegeEOASpGYFqg0wh X-IronPort-AV: E=Sophos;i="4.97,753,1389762000"; d="scan'208";a="76322277" Original-Received: from 75-119-224-253.dsl.teksavvy.com (HELO ceviche.home) ([75.119.224.253]) by ironport2-out.teksavvy.com with ESMTP/TLS/ADH-AES256-SHA; 03 Jul 2014 21:26:35 -0400 Original-Received: by ceviche.home (Postfix, from userid 20848) id B0488660FA; Thu, 3 Jul 2014 21:26:35 -0400 (EDT) In-Reply-To: (=?windows-1252?Q?=22Aur=E9lien?= Aptel"'s message of "Wed, 2 Jul 2014 22:54:27 +0200") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.4.50 (gnu/linux) X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 206.248.154.181 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:172881 Archived-At: > At first I was calling the libtool init function (lt_dlinit) in > syms_of_lread() but it made every subsequent call to lt_dlopen > segfault. I think the problem was coming from calling it before > dumping because as soon as I moved it to the body of `load-module' it > started working. It should maybe be called in an init_* function rather than a syms_of_* function: the difference is that syms_of_* functions are called only once, before dumping, whereas the init_* functions are re-executed every time Emacs is started (i.e. before and after the dump). But calling it from Fload_module is probably fine as well (and maybe even better). > - /* Creating a non-pure string from a string literal not > - implemented yet. We could just use make_string here and live > - with the extra copy. */ > - emacs_abort (); > + return Fintern (make_string (str, len), obarray); That's OK, tho you might keep a comment about the need to make a duplicate copy of the string because a heap-allocated Lisp_String can't point to a string literal. Stefan