libtool-patches
[Top][All Lists]
Advanced

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

Re: Error reporting should be improved


From: Bob Friesenhahn
Subject: Re: Error reporting should be improved
Date: Tue, 29 Dec 2009 23:39:44 -0600 (CST)
User-agent: Alpine 2.01 (GSO 1266 2009-07-14)

On Wed, 30 Dec 2009, Peter Rosin wrote:

The thread safety thing can be ignored as libltdl isn't thread safe
and needs to be mutexed anyway. Care to test this patch?

There used to be some useless effort to make it thread safe. Apparently that is gone now. Regardless, there is also a potential re-entrancy issue, which could be encountered if a legacy OS interface is supported (re-implemented) via dlopen() or if some other implementation logic (e.g. lazy symbol resolution) uses dlsym().

An alternative approach would be to store loader-specific errors in loader-specific storage and iterate through the loaders in order to obtain their error messages.

With this patch, how will the accumulated error strings be reported to the API user? Some of the error reports will be useless and so it may not be useful to combine them since a useless report would have the same significance as an important one. The origin (id of the reporting loader) would be useful to record. If the origin was part of the string (or the string is owned by the loader) then that would serve to keep them distinct.

Unfortunately, lt_dladderror() is publically exposed so it is difficult to change its arguments even though it is not documented.

Bob
--
Bob Friesenhahn
address@hidden, http://www.simplesystems.org/users/bfriesen/
GraphicsMagick Maintainer,    http://www.GraphicsMagick.org/




reply via email to

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