Below is the list of changes that have just been committed into a local
5.1 repository of serg. When serg does a push these changes will
be propagated to the main repository and, within 24 hours after the
push, to the public repository.
For information on how to access the public repository
see http://dev.mysql.com/doc/mysql/en/installing-source-tree.html
ChangeSet
1.2079 06/02/07 15:24:34 serg@stripped +2 -0
fixes for the ER_CANT_OPEN_LIBRARY message
sql/sql_plugin.cc
1.11 06/02/07 15:24:20 serg@stripped +13 -4
1. dlerror() cannot be called twice
2. remove dlpath from dlerror() messages
sql/share/errmsg.txt
1.81 06/02/07 15:24:20 serg@stripped +7 -7
.64s is too short for dlerror() messages
# This is a BitKeeper patch. What follows are the unified diffs for the
# set of deltas contained in the patch. The rest of the patch, the part
# that BitKeeper cares about, is below these diffs.
# User: serg
# Host: serg.mylan
# Root: /usr/home/serg/Abk/mysql-5.1
--- 1.80/sql/share/errmsg.txt Mon Feb 6 21:30:33 2006
+++ 1.81/sql/share/errmsg.txt Tue Feb 7 15:24:20 2006
@@ -2981,11 +2981,11 @@ ER_CANT_OPEN_LIBRARY
nla "Kan shared library '%-.64s' niet openen (Errcode: %d %s)"
- eng "Can't open shared library '%-.64s' (errno: %d %-.64s)"
+ eng "Can't open shared library '%-.64s' (errno: %d %s)"
- est "Ei suuda avada jagatud teeki '%-.64s' (veakood: %d %-.64s)"
+ est "Ei suuda avada jagatud teeki '%-.64s' (veakood: %d %s)"
hun "A(z) '%-.64s' megosztott konyvtar nem hasznalhato (hibakod: %d %s)"
ita "Impossibile aprire la libreria condivisa '%-.64s' (errno: %d %s)"
@@ -2995,13 +2995,13 @@ ER_CANT_OPEN_LIBRARY
norwegian-ny "Can't open shared library '%-.64s' (errno: %d %s)"
pol "Can't open shared library '%-.64s' (errno: %d %s)"
- rum "Nu pot deschide libraria shared '%-.64s' (Eroare: %d %-.64s)"
- serbian "Ne mogu da otvorim share-ovanu biblioteku '%-.64s' (errno: %d %-.64s)"
+ rum "Nu pot deschide libraria shared '%-.64s' (Eroare: %d %s)"
+ serbian "Ne mogu da otvorim share-ovanu biblioteku '%-.64s' (errno: %d %s)"
spa "No puedo abrir libraria conjugada '%-.64s' (errno: %d %s)"
ER_CANT_FIND_DL_ENTRY
dan "Kan ikke finde funktionen '%-.64s' i bibliotek"
--- 1.10/sql/sql_plugin.cc Sat Jan 7 14:49:42 2006
+++ 1.11/sql/sql_plugin.cc Tue Feb 7 15:24:20 2006
@@ -105,7 +105,7 @@ static st_plugin_dl *plugin_dl_add(LEX_S
{
#ifdef HAVE_DLOPEN
char dlpath[FN_REFLEN];
- uint plugin_dir_len, dummy_errors;
+ uint plugin_dir_len, dummy_errors, dlpathlen;
struct st_plugin_dl *tmp, plugin_dl;
void *sym;
DBUG_ENTER("plugin_dl_add");
@@ -133,15 +133,24 @@ static st_plugin_dl *plugin_dl_add(LEX_S
}
bzero(&plugin_dl, sizeof(plugin_dl));
/* Compile dll path */
- strxnmov(dlpath, sizeof(dlpath) - 1, opt_plugin_dir, "/", dl->str, NullS);
+ dlpathlen=
+ strxnmov(dlpath, sizeof(dlpath) - 1, opt_plugin_dir, "/", dl->str, NullS) -
+ dlpath;
plugin_dl.ref_count= 1;
/* Open new dll handle */
if (!(plugin_dl.handle= dlopen(dlpath, RTLD_NOW)))
{
+ const char *errmsg=dlerror();
+ if (!strncmp(dlpath, errmsg, dlpathlen))
+ { // if errmsg starts from dlpath, trim this prefix.
+ errmsg+=dlpathlen;
+ if (*errmsg == ':') errmsg++;
+ if (*errmsg == ' ') errmsg++;
+ }
if (report & REPORT_TO_USER)
- my_error(ER_CANT_OPEN_LIBRARY, MYF(0), dlpath, errno, dlerror());
+ my_error(ER_CANT_OPEN_LIBRARY, MYF(0), dlpath, errno, errmsg);
if (report & REPORT_TO_LOG)
- sql_print_error(ER(ER_CANT_OPEN_LIBRARY), dlpath, errno, dlerror());
+ sql_print_error(ER(ER_CANT_OPEN_LIBRARY), dlpath, errno, errmsg);
DBUG_RETURN(0);
}
/* Determine interface version */
| Thread |
|---|
| • bk commit into 5.1 tree (serg:1.2079) | Sergei Golubchik | 7 Feb |