mudflap and dlopen

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

 



Hi all,

I hope this is the right mailing list. I am the author of rsyslog, a
modular and multi-threaded syslogd. I try to hunt down a memory
adressing problem with mudflap, but I get some reports that I really
can't understand.

What happens is that these reports come up from inside a dlload()'ed
module which is called from the main binary. The main program passes
in two paramaters, a string (pointer to unsigned char) and a pointer
to a function pointer. The module's entry point compares the string
and writes the correct function address to the function pointer. All
accesses to these two variables seem to trigger mudflap violations.

I have checked the pointer sizes are correctly.

I have compiled and linked the main program with -fmudflapth
-lmudflapth and have compiled the module with -fmudflapth, but not
linked it with any special directive (my understanding is that
load-time linking will then link the module to the main program's
mudflap libraries, what I think it is the correct thing to do).

To double-check, I have then linked both the main program and the
module against libmudflapth, and these problems disappear then. So the
conclusion is probably straightforward. However, I still have a hang
condition on some module loads when mudflap is enabled (and only
then).

So I wonder if I am doing something wrong and if there are any known
problems with dlload(). Any feedback would be appreciated.

Thanks,
Rainer

[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux