From: Ralf Wildenhues Date: Tue, 4 Mar 2008 22:31:33 +0000 (+0000) Subject: Fix libltdl to not skip dlopen on systems with several loaders, X-Git-Tag: v2.2.2~22 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=3280cb4b7cbcba1d5470f2b7c74096b467322141;p=thirdparty%2Flibtool.git Fix libltdl to not skip dlopen on systems with several loaders, such as HP-UX, Cygwin. * libltdl/slist.c (slist_concat): When appending to the tail of a list, do not drop items off the beginning of the list. * NEWS: Update. --- diff --git a/ChangeLog b/ChangeLog index f37276e21..ee4ff3dde 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,11 @@ 2008-03-04 Ralf Wildenhues + Fix libltdl to not skip dlopen on systems with several loaders, + such as HP-UX, Cygwin. + * libltdl/slist.c (slist_concat): When appending to the tail + of a list, do not drop items off the beginning of the list. + * NEWS: Update. + * libltdl/config/ltmain.m4sh (func_mode_execute): Replace only arguments we have identified as shell or C wrappers. (func_emit_wrapper): Output error message on stderr. diff --git a/NEWS b/NEWS index 80c4ebda2..e56e04584 100644 --- a/NEWS +++ b/NEWS @@ -6,6 +6,8 @@ New in 2.3b: 2008-??-??: CVS version 2.3a, Libtool team: - Fix 2.2 regression in libltdl that causes memory corruption upon repeated `lt_dlinit(); lt_dlexit()'. + - Fix 2.2 regression in libltdl that skipped the dlopen loader if + the system also supports other loaders (e.g., Cygwin, HP-UX). - Fix 2.2 regression in that `libtool --mode=execute CMD ARGS' does not transform ARGS that do not look like shell or C wrappers of libtool programs. diff --git a/libltdl/slist.c b/libltdl/slist.c index deeb8e833..c99f39914 100644 --- a/libltdl/slist.c +++ b/libltdl/slist.c @@ -1,6 +1,6 @@ /* slist.c -- generalised singly linked lists - Copyright (C) 2000, 2004, 2007 Free Software Foundation, Inc. + Copyright (C) 2000, 2004, 2007, 2008 Free Software Foundation, Inc. Written by Gary V. Vaughan, 2000 NOTE: The canonical source of this file is maintained with the @@ -140,15 +140,18 @@ slist_find (SList *slist, SListCallback *find, void *matchdata) SList * slist_concat (SList *head, SList *tail) { + SList *last; + if (!head) { return tail; } - while (head->next) - head = head->next; + last = head; + while (last->next) + last = last->next; - head->next = tail; + last->next = tail; return head; }