Below is the list of changes that have just been committed into a local
5.1 repository of msvensson. When msvensson 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@stripped, 2006-12-22 12:14:37+01:00, msvensson@stripped +1 -0
Merge pilot.mysql.com:/home/msvensson/mysql/my51-ndb-gca-my51-m
into pilot.mysql.com:/home/msvensson/mysql/mysql-5.1-new-ndb
MERGE: 1.2356.3.1
sql/sql_plugin.cc@stripped, 2006-12-22 12:14:35+01:00, msvensson@stripped +0 -0
Auto merged
MERGE: 1.40.1.1
# 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: msvensson
# Host: pilot.mysql.com
# Root: /home/msvensson/mysql/mysql-5.1-new-ndb/RESYNC
--- 1.42/sql/sql_plugin.cc 2006-12-22 12:14:11 +01:00
+++ 1.43/sql/sql_plugin.cc 2006-12-22 12:14:35 +01:00
@@ -951,29 +951,30 @@
state_mask= ~state_mask; // do it only once
rw_rdlock(&THR_LOCK_plugin);
+ total= type == MYSQL_ANY_PLUGIN ? plugin_array.elements
+ : plugin_hash[type].records;
+ /*
+ Do the alloca out here in case we do have a working alloca:
+ leaving the nested stack frame invalidates alloca allocation.
+ */
+ plugins=(struct st_plugin_int **)my_alloca(total*sizeof(*plugins));
if (type == MYSQL_ANY_PLUGIN)
{
- total=plugin_array.elements;
- plugins=(struct st_plugin_int **)my_alloca(total*sizeof(*plugins));
for (idx= 0; idx < total; idx++)
{
plugin= dynamic_element(&plugin_array, idx, struct st_plugin_int *);
- if (plugin->state & state_mask)
- continue;
- plugins[idx]= plugin;
+ plugins[idx]= !(plugin->state & state_mask) ? plugin : NULL;
}
}
else
{
- HASH *hash= &plugin_hash[type];
- total=hash->records;
- plugins=(struct st_plugin_int **)my_alloca(total*sizeof(*plugins));
+ HASH *hash= plugin_hash + type;
for (idx= 0; idx < total; idx++)
{
plugin= (struct st_plugin_int *) hash_element(hash, idx);
if (plugin->state & state_mask)
continue;
- plugins[idx]= plugin;
+ plugins[idx]= !(plugin->state & state_mask) ? plugin : NULL;
}
}
rw_unlock(&THR_LOCK_plugin);
| Thread |
|---|
| • bk commit into 5.1 tree (msvensson:1.2378) | msvensson | 22 Dec |