+2007-06-24 Gary V. Vaughan <gary@gnu.org>
+
+ Reenable compilation of libltdl with C++:
+
+ * libltdl/ltdl.c (tryall_dlopen): Rename the try variable to
+ attempt, and cast explicitly.
+ (advise_dup): Add explicit cast.
+
2007-06-22 Peter O'Gorman <peter@pogma.com>
* libltdl/config/ltmain.m4sh (version-number) [irix]: Don't subtract
lt__advise *advise_taken = 0;
if (advise)
- advise_taken = advise_dup (advise);
+ advise_taken = advise_dup ((lt__advise *) advise);
vtable = lt_dlloader_get (loader);
handle->module = (*vtable->module_open) (vtable->dlloader_data,
char * base_name = 0;
char * dir = 0;
char * name = 0;
- char * try = 0;
+ char * attempt = 0;
int errors = 0;
lt_dlhandle newhandle;
if (ext)
{
- try = MALLOC (char, LT_STRLEN (filename) + LT_STRLEN (ext) + 1);
- if (!try)
+ attempt = MALLOC (char, LT_STRLEN (filename) + LT_STRLEN (ext) + 1);
+ if (!attempt)
return 1;
- sprintf(try, "%s%s", filename, ext);
+ sprintf(attempt, "%s%s", filename, ext);
}
else
{
- try = lt__strdup (filename);
- if (!try)
+ attempt = lt__strdup (filename);
+ if (!attempt)
return 1;
}
/* Doing this immediately allows internal functions to safely
assume only canonicalized paths are passed. */
- if (canonicalize_path (try, &canonical) != 0)
+ if (canonicalize_path (attempt, &canonical) != 0)
{
++errors;
goto cleanup;
cleanup:
FREE (dir);
- FREE (try);
+ FREE (attempt);
FREE (name);
if (!canonical) /* was MEMREASSIGNed */
FREE (base_name);
advise_dup (lt__advise *advise)
{
lt__advise *dup = (lt__advise *) lt__zalloc (sizeof (lt__advise));
- return memcpy (dup, advise, sizeof (lt__advise));
+ return (lt__advise *) memcpy (dup, advise, sizeof (lt__advise));
}
/* Libtool-1.5.x interface for loading a new module named FILENAME. */