Merge mysql.com:/Users/kent/mysql/bk/mysql-5.1-release

into  mysql.com:/Users/kent/mysql/bk/mysql-5.1
parents 4a7cd3a1 87a9d234
......@@ -66,7 +66,7 @@ INSTALL-BINARY: mysql.info $(GT)
# It is not in BitKeeper, but is downloaded from intranet by Bootstrap.
dist-hook:
if [ -e $(srcdir)/manual.chm ] ; then \
cp $(srcdir)/manual.chm $(distdir); \
cp -f $(srcdir)/manual.chm $(distdir); \
fi
# Don't update the files from bitkeeper
......
......@@ -65,6 +65,9 @@ TARGET_LINK_LIBRARIES(mysqldump mysqlclient mysys dbug yassl taocrypt zlib wsock
ADD_EXECUTABLE(mysqlimport mysqlimport.c)
TARGET_LINK_LIBRARIES(mysqlimport mysqlclient mysys dbug yassl taocrypt zlib wsock32)
ADD_EXECUTABLE(mysql_upgrade mysql_upgrade.c)
TARGET_LINK_LIBRARIES(mysql_upgrade mysqlclient mysys dbug yassl taocrypt zlib wsock32)
ADD_EXECUTABLE(mysqlshow mysqlshow.c)
TARGET_LINK_LIBRARIES(mysqlshow mysqlclient mysys dbug yassl taocrypt zlib wsock32)
......
......@@ -1441,9 +1441,9 @@ fi
# dlopen, dlerror
case "$with_mysqld_ldflags " in
*"-static "*)
*"-all-static "*)
# No need to check for dlopen when mysqld is linked with
# -all-static or -static as it won't be able to load any functions.
# -all-static as it won't be able to load any functions.
# NOTE! It would be better if it was possible to test if dlopen
# can be used, but a good way to test it couldn't be found
......
......@@ -614,12 +614,17 @@ C_MODE_END
#define _STATIC_VARARGS(X) X
#define _PC(X) X
/* The DBUG_ON flag always takes precedence over default DBUG_OFF */
#if defined(DBUG_ON) && defined(DBUG_OFF)
#undef DBUG_OFF
#endif
#if defined(_lint) && !defined(DBUG_OFF)
#define DBUG_OFF
/* We might be forced to turn debug off, if not turned off already */
#if (defined(FORCE_DBUG_OFF) || defined(_lint)) && !defined(DBUG_OFF)
# define DBUG_OFF
# ifdef DBUG_ON
# undef DBUG_ON
# endif
#endif
#include <my_dbug.h>
......
This diff is collapsed.
......@@ -23,7 +23,6 @@ ndb_autodiscover2 : BUG#18952 2006-02-16 jmiller Needs to be fixed w.r.t
#ndb_binlog_ignore_db : BUG#21279 2006-07-25 ingo Randomly throws a warning
ndb_load : BUG#17233 2006-05-04 tomas failed load data from infile causes mysqld dbug_assert, binlog not flushed
partition_03ndb : BUG#16385 2006-03-24 mikael Partitions: crash when updating a range partitioned NDB table
ps : BUG#21524 2006-08-08 pgalbraith 'ps' test fails in --ps-protocol test AMD64 bit
ps_7ndb : BUG#18950 2006-02-16 jmiller create table like does not obtain LOCK_open
rpl_ndb_2innodb : BUG#19227 2006-04-20 pekka pk delete apparently not replicated
rpl_ndb_2myisam : BUG#19227 Seems to pass currently
......
This diff is collapsed.
......@@ -15,8 +15,7 @@
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
/* To avoid problems with alarms in debug code, we disable DBUG here */
#undef DBUG_OFF
#define DBUG_OFF
#define FORCE_DBUG_OFF
#include <my_global.h>
#if defined(THREAD) && !defined(DONT_USE_THR_ALARM)
......
......@@ -72,7 +72,7 @@ multiple read locks.
*/
#if !defined(MAIN) && !defined(DBUG_OFF) && !defined(EXTRA_DEBUG)
#define DBUG_OFF
#define FORCE_DBUG_OFF
#endif
#include "mysys_priv.h"
......
......@@ -5,8 +5,11 @@
# stop on errors
set -e
sed -e "s/^DIST_COMMON/#DIST_COMMON/g" storage/ndb/Makefile.am > storage/ndb/Makefile.am.$$
mv storage/ndb/Makefile.am.$$ storage/ndb/Makefile.am
for package in . ./storage/innobase
# for package in . ./storage/innobase
for package in .
do
(cd $package
rm -rf config.cache autom4te.cache
......@@ -14,6 +17,7 @@ do
autoheader
libtoolize --force
aclocal
# automake --verbose --add-missing --force-missing
automake --add-missing --force-missing
autoconf)
done
......
......@@ -24,5 +24,4 @@ base_configs=" \
--prefix=N:/mysql \
--without-mysqlmanager \
--without-man \
--without-csv-storage-engine \
"
......@@ -8,7 +8,7 @@ fi
# The base path(in wineformat) where compilers, includes and
# libraries are installed
if test -z $MYDEV
if test -z "$MYDEV"
then
# the default is "F:/mydev"
export MYDEV="F:/mydev"
......
......@@ -151,17 +151,18 @@ echo "making files writable..."
cd $target_dir
chmod -R u+rw,g+rw .
# edit the mvenv file
echo "updating the mwenv environment file..."
## # edit the mvenv file
## echo "updating the mwenv environment file..."
mwenv="./netware/BUILD/mwenv"
mv -f $mwenv $mwenv.org
sed -e "s;WINE_BUILD_DIR;$wine_build_dir;g" \
-e "s;BUILD_DIR;$build_dir;g" \
-e "s;VERSION;$version;g" $mwenv.org > $mwenv
chmod +rwx $mwenv
## mv -f $mwenv $mwenv.org
## sed -e "s;WINE_BUILD_DIR;$wine_build_dir;g" \
## -e "s;BUILD_DIR;$build_dir;g" \
## -e "s;VERSION;$version;g" $mwenv.org > $mwenv
## chmod +rwx $mwenv
PWD=`pwd`
SRC_DIR=`grep "^export MYDEV=" $mwenv | cut -d'=' -f2 | \
# This line will catch the default value only, let's hope it is correct
SRC_DIR=`grep "^ *export MYDEV=" $mwenv | cut -d'=' -f2 | \
sed -e 's;";;g' -e "s;^;echo ;g" -e "s;$;/\`basename $PWD\`;g" | /bin/sh`
......
......@@ -253,8 +253,8 @@ $CP mysql-test/t/*.test $BASE/mysql-test/t
$CP mysql-test/t/*.imtest mysql-test/t/*.disabled $BASE/mysql-test/t
$CP mysql-test/t/*.opt mysql-test/t/*.slave-mi $BASE/mysql-test/t
$CP mysql-test/t/*.sh mysql-test/t/*.sql $BASE/mysql-test/t
$CP mysql-test/r/*.result mysql-test/r/*.require \
$BASE/mysql-test/r
$CP mysql-test/r/*.result $BASE/mysql-test/r
$CP mysql-test/r/*.require $BASE/mysql-test/r
$CP mysql-test/extra/binlog_tests/*.test $BASE/mysql-test/extra/binlog_tests
$CP mysql-test/extra/rpl_tests/*.test $BASE/mysql-test/extra/rpl_tests
......@@ -326,14 +326,16 @@ fi
# NDB Cluster
if [ x$NDBCLUSTER = x1 ]; then
( cd storage/ndb ; @MAKE@ DESTDIR=$BASE/ndb-stage install )
( cd mysql-test/ndb ; @MAKE@ DESTDIR=$BASE/ndb-stage install )
( cd storage/ndb ; @MAKE@ DESTDIR=$BASE/ndb-stage install )
( cd mysql-test ; @MAKE@ DESTDIR=$BASE/ndb-stage install )
$CP $BASE/ndb-stage@bindir@/* $BASE/bin/.
$CP $BASE/ndb-stage@libexecdir@/* $BASE/bin/.
$CP $BASE/ndb-stage@pkglibdir@/* $BASE/lib/.
test -d $BASE/include/storage || mkdir $BASE/include/storage
$CP -r $BASE/ndb-stage@pkgincludedir@/storage/ndb $BASE/include/storage/
$CP -r $BASE/ndb-stage@prefix@/mysql-test/ndb $BASE/mysql-test/. || exit 1
$CP -r $BASE/ndb-stage@prefix@/mysql-test/std_data/ndb_backup50 $BASE/mysql-test/std_data/. || exit 1
$CP -r $BASE/ndb-stage@prefix@/mysql-test/std_data/ndb_backup51 $BASE/mysql-test/std_data/. || exit 1
rm -rf $BASE/ndb-stage
fi
......
......@@ -27,7 +27,7 @@ INCLUDES = @ZLIB_INCLUDES@ \
WRAPLIBS= @WRAPLIBS@
SUBDIRS = share
libexec_PROGRAMS = mysqld
EXTRA_PROGRAMS = gen_lex_hash
noinst_PROGRAMS = gen_lex_hash
bin_PROGRAMS = mysql_tzinfo_to_sql
gen_lex_hash_LDFLAGS = @NOINST_LDFLAGS@
LDADD = $(top_builddir)/vio/libvio.a \
......@@ -120,8 +120,9 @@ DEFS = -DMYSQL_SERVER \
-DLIBDIR="\"$(MYSQLLIBdir)\"" \
@DEFS@
BUILT_SOURCES = sql_yacc.cc sql_yacc.h lex_hash.h
EXTRA_DIST = udf_example.c udf_example.def $(BUILT_SOURCES) \
BUILT_DIST_SRC = sql_yacc.cc sql_yacc.h
BUILT_SOURCES = $(BUILT_DIST_SRC) lex_hash.h
EXTRA_DIST = udf_example.c udf_example.def $(BUILT_DIST_SRC) \
nt_servc.cc nt_servc.h message.mc CMakeLists.txt \
udf_example.c udf_example.def
CLEANFILES = lex_hash.h sql_yacc.cc sql_yacc.h sql_yacc.output
......@@ -157,11 +158,10 @@ sql_yacc.o: sql_yacc.cc sql_yacc.h $(HEADERS)
@echo "If it fails, re-run configure with --with-low-memory"
$(CXXCOMPILE) $(LM_CFLAGS) -c $<
# This generates lex_hash.h
# NOTE Built sources should depend on their sources not the tool
# this avoid the rebuild of the built files in a source dist
lex_hash.h: gen_lex_hash.cc lex.h
$(MAKE) $(AM_MAKEFLAGS) gen_lex_hash$(EXEEXT)
# FIXME seems like now "lex_hash.h" differs depending on configure
# flags, so can't pregenerate and include in source TAR. Revert to
# dist pregenerated if this changes, so the file doesn't differ.
lex_hash.h: gen_lex_hash$(EXEEXT)
./gen_lex_hash$(EXEEXT) > $@
# the following three should eventually be moved out of this directory
......
......@@ -7129,8 +7129,8 @@ int Update_rows_log_event::do_prepare_row(THD *thd, RELAY_LOG_INFO *rli,
row_start, &m_cols, row_end, &m_master_reclength,
table->write_set, UPDATE_ROWS_EVENT);
DBUG_DUMP("record[0]", table->record[0], table->s->reclength);
DBUG_DUMP("m_after_image", m_after_image, table->s->reclength);
DBUG_DUMP("record[0]", (const char *)table->record[0], table->s->reclength);
DBUG_DUMP("m_after_image", (const char *)m_after_image, table->s->reclength);
/*
......
......@@ -2632,10 +2632,10 @@ int THD::binlog_update_row(TABLE* table, bool is_trans,
my_size_t const after_size= pack_row(table, cols, after_row,
after_record);
DBUG_DUMP("before_record", before_record, table->s->reclength);
DBUG_DUMP("after_record", after_record, table->s->reclength);
DBUG_DUMP("before_row", before_row, before_size);
DBUG_DUMP("after_row", after_row, after_size);
DBUG_DUMP("before_record", (const char *)before_record, table->s->reclength);
DBUG_DUMP("after_record", (const char *)after_record, table->s->reclength);
DBUG_DUMP("before_row", (const char *)before_row, before_size);
DBUG_DUMP("after_row", (const char *)after_row, after_size);
Rows_log_event* const ev=
binlog_prepare_pending_rows_event(table, server_id, cols, colcnt,
......
......@@ -75,7 +75,7 @@ Dbtup::dump_disk_alloc(Dbtup::Disk_alloc_info & alloc)
for(Uint32 i = 0; i<MAX_FREE_LIST; i++)
{
printf(" %d : ", i);
Ptr<Page> ptr;
PagePtr ptr;
ArrayPool<Page> *pool= (ArrayPool<Page>*)&m_global_page_pool;
LocalDLList<Page> list(*pool, alloc.m_dirty_pages[i]);
for(list.first(ptr); !ptr.isNull(); list.next(ptr))
......@@ -262,7 +262,7 @@ Dbtup::update_extent_pos(Disk_alloc_info& alloc,
}
void
Dbtup::restart_setup_page(Disk_alloc_info& alloc, Ptr<Page> pagePtr)
Dbtup::restart_setup_page(Disk_alloc_info& alloc, PagePtr pagePtr)
{
/**
* Link to extent, clear uncommitted_used_space
......@@ -344,12 +344,15 @@ Dbtup::disk_page_prealloc(Signal* signal,
if (!alloc.m_dirty_pages[i].isEmpty())
{
ptrI= alloc.m_dirty_pages[i].firstItem;
Ptr<GlobalPage> page;
m_global_page_pool.getPtr(page, ptrI);
Ptr<GlobalPage> gpage;
m_global_page_pool.getPtr(gpage, ptrI);
disk_page_prealloc_dirty_page(alloc, *(PagePtr*)&page, i, sz);
key->m_page_no= ((Page*)page.p)->m_page_no;
key->m_file_no= ((Page*)page.p)->m_file_no;
PagePtr tmp;
tmp.i = gpage.i;
tmp.p = reinterpret_cast<Page*>(gpage.p);
disk_page_prealloc_dirty_page(alloc, tmp, i, sz);
key->m_page_no= tmp.p->m_page_no;
key->m_file_no= tmp.p->m_file_no;
if (DBG_DISK)
ndbout << " found dirty page " << *key << endl;
return 0; // Page in memory
......@@ -547,7 +550,7 @@ Dbtup::disk_page_prealloc(Signal* signal,
void
Dbtup::disk_page_prealloc_dirty_page(Disk_alloc_info & alloc,
Ptr<Page> pagePtr,
PagePtr pagePtr,
Uint32 old_idx, Uint32 sz)
{
ddassert(pagePtr.p->list_index == old_idx);
......@@ -638,7 +641,9 @@ Dbtup::disk_page_prealloc_callback(Signal* signal,
fragPtr.i= req.p->m_frag_ptr_i;
ptrCheckGuard(fragPtr, cnoOfFragrec, fragrecord);
Ptr<Page> pagePtr = *(Ptr<Page>*)&gpage;
PagePtr pagePtr;
pagePtr.i = gpage.i;
pagePtr.p = reinterpret_cast<Page*>(gpage.p);
if (unlikely(pagePtr.p->m_restart_seq != globalData.m_restart_seq))
{
......@@ -666,7 +671,9 @@ Dbtup::disk_page_prealloc_initial_callback(Signal*signal,
Ptr<GlobalPage> gpage;
m_global_page_pool.getPtr(gpage, page_id);
Ptr<Page> pagePtr = *(Ptr<Page>*)&gpage;
PagePtr pagePtr;
pagePtr.i = gpage.i;
pagePtr.p = reinterpret_cast<Page*>(gpage.p);
Ptr<Fragrecord> fragPtr;
fragPtr.i= req.p->m_frag_ptr_i;
......@@ -705,7 +712,7 @@ void
Dbtup::disk_page_prealloc_callback_common(Signal* signal,
Ptr<Page_request> req,
Ptr<Fragrecord> fragPtr,
Ptr<Page> pagePtr)
PagePtr pagePtr)
{
/**
* 1) remove page request from Disk_alloc_info.m_page_requests
......@@ -736,7 +743,7 @@ Dbtup::disk_page_prealloc_callback_common(Signal* signal,
*/
ArrayPool<Page> *cheat_pool= (ArrayPool<Page>*)&m_global_page_pool;
LocalDLList<Page> list(* cheat_pool, alloc.m_dirty_pages[new_idx]);
list.add(*(Ptr<Page>*)&pagePtr);
list.add(pagePtr);
pagePtr.p->uncommitted_used_space = real_used;
pagePtr.p->list_index = new_idx;
......@@ -765,7 +772,7 @@ Dbtup::disk_page_prealloc_callback_common(Signal* signal,
}
void
Dbtup::disk_page_set_dirty(Ptr<Page> pagePtr)
Dbtup::disk_page_set_dirty(PagePtr pagePtr)
{
Uint32 idx = pagePtr.p->list_index;
if ((idx & 0x8000) == 0)
......@@ -833,7 +840,9 @@ Dbtup::disk_page_unmap_callback(Uint32 page_id, Uint32 dirty_count)
{
Ptr<GlobalPage> gpage;
m_global_page_pool.getPtr(gpage, page_id);
PagePtr pagePtr= *(PagePtr*)&gpage;
PagePtr pagePtr;
pagePtr.i = gpage.i;
pagePtr.p = reinterpret_cast<Page*>(gpage.p);
Uint32 type = pagePtr.p->m_page_header.m_page_type;
if (unlikely((type != File_formats::PT_Tup_fixsize_page &&
......@@ -1028,10 +1037,13 @@ Dbtup::disk_page_abort_prealloc(Signal *signal, Fragrecord* fragPtrP,
case -1:
break;
default:
Ptr<GlobalPage> page;
m_global_page_pool.getPtr(page, (Uint32)res);
disk_page_abort_prealloc_callback_1(signal, fragPtrP, *(PagePtr*)&page,
sz);
Ptr<GlobalPage> gpage;
m_global_page_pool.getPtr(gpage, (Uint32)res);
PagePtr pagePtr;
pagePtr.i = gpage.i;
pagePtr.p = reinterpret_cast<Page*>(gpage.p);
disk_page_abort_prealloc_callback_1(signal, fragPtrP, pagePtr, sz);
}
}
......@@ -1044,8 +1056,10 @@ Dbtup::disk_page_abort_prealloc_callback(Signal* signal,
Ptr<GlobalPage> gpage;
m_global_page_pool.getPtr(gpage, page_id);
PagePtr pagePtr= *(PagePtr*)&gpage;
PagePtr pagePtr;
pagePtr.i = gpage.i;
pagePtr.p = reinterpret_cast<Page*>(gpage.p);
Ptr<Tablerec> tabPtr;
tabPtr.i= pagePtr.p->m_table_id;
ptrCheckGuard(tabPtr, cnoOfTablerec, tablerec);
......@@ -1308,7 +1322,9 @@ Dbtup::disk_restart_undo_callback(Signal* signal,
jamEntry();
Ptr<GlobalPage> gpage;
m_global_page_pool.getPtr(gpage, page_id);
Ptr<Page> pagePtr = *(Ptr<Page>*)&gpage;
PagePtr pagePtr;
pagePtr.i = gpage.i;
pagePtr.p = reinterpret_cast<Page*>(gpage.p);
Apply_undo* undo = &f_undo;
......
......@@ -1039,22 +1039,19 @@ int Dbtup::handleUpdateReq(Signal* signal,
tup_version= (tup_version + 1) & ZTUP_VERSION_MASK;
operPtrP->tupVersion= tup_version;
int retValue;
if (!req_struct->interpreted_exec) {
jam();
retValue= updateAttributes(req_struct,
&cinBuffer[0],
req_struct->attrinfo_len);
int retValue = updateAttributes(req_struct,
&cinBuffer[0],
req_struct->attrinfo_len);
if (unlikely(retValue == -1))
goto error;
} else {
jam();
if (unlikely(interpreterStartLab(signal, req_struct) == -1))
return -1;
}
if (retValue == -1) {
goto error;
}
if (regTabPtr->need_shrink())
{
shrink_tuple(req_struct, sizes+2, regTabPtr, disk);
......@@ -1073,7 +1070,7 @@ int Dbtup::handleUpdateReq(Signal* signal,
jam();
setChecksum(req_struct->m_tuple_ptr, regTabPtr);
}
return retValue;
return 0;
error:
tupkeyErrorLab(signal);
......
......@@ -305,7 +305,11 @@ inline
bool
RecordPool<T, P>::seize(Ptr<T> & ptr)
{
return m_pool.seize(*(Ptr<void>*)&ptr);
Ptr<void> tmp;
bool ret = m_pool.seize(tmp);
ptr.i = tmp.i;
ptr.p = static_cast<T*>(tmp.p);
return ret;
}
template <typename T, typename P>
......
......@@ -701,7 +701,7 @@ void NdbScanOperation::close(bool forceSend, bool releaseOp)
theNdbCon = NULL;
m_transConnection = NULL;
if (tTransCon)
if (tTransCon && releaseOp)
{
NdbIndexScanOperation* tOp = (NdbIndexScanOperation*)this;
......@@ -716,7 +716,7 @@ void NdbScanOperation::close(bool forceSend, bool releaseOp)
&tTransCon->m_theLastScanOperation,
tOp);
}
else if (releaseOp)
else
{
ret = tTransCon->releaseScanOperation(&tTransCon->m_firstExecutedScanOp,
0, tOp);
......
......@@ -327,7 +327,7 @@ then
cp -fp mysql-debug-%{mysql_version}/config.log "$MYSQL_DEBUGCONFLOG_DEST"
fi
(cd mysql-debug-%{mysql_version} ; \
(cd mysql-debug-%{mysql_version}/mysql-test ; \
./mysql-test-run.pl --comment=debug --skip-rpl --skip-ndbcluster --force ; \
true)
......@@ -357,12 +357,13 @@ then
cp -fp mysql-release-%{mysql_version}/config.log "$MYSQL_CONFLOG_DEST"
fi
(cd mysql-release-%{mysql_version} ; \
./mysql-test-run.pl --comment=normal --force ; \
./mysql-test-run.pl --comment=ps --ps-protocol --force ; \
./mysql-test-run.pl --comment=normal+rowrepl --mysqld=--binlog-format=row --force ; \
./mysql-test-run.pl --comment=ps+rowrepl --ps-protocol --mysqld=--binlog-format=row --force ; \
true)
cd mysql-release-%{mysql_version}/mysql-test
./mysql-test-run.pl --comment=normal --force --skip-ndbcluster --timer || true
./mysql-test-run.pl --comment=ps --ps-protocol --force --skip-ndbcluster --timer || true
./mysql-test-run.pl --comment=normal+rowrepl --mysqld=--binlog-format=row --force --skip-ndbcluster --timer || true
./mysql-test-run.pl --comment=ps+rowrepl+NDB --ps-protocol --mysqld=--binlog-format=row --force --timer || true
./mysql-test-run.pl --comment=NDB --with-ndbcluster-only --force --timer || true
cd ../..
##############################################################################
......@@ -522,7 +523,6 @@ fi
%doc %attr(644, root, man) %{_mandir}/man1/myisamchk.1*
%doc %attr(644, root, man) %{_mandir}/man1/myisamlog.1*
%doc %attr(644, root, man) %{_mandir}/man1/myisampack.1*
%doc %attr(644, root, man) %{_mandir}/man1/mysql_explain_log.1*
%doc %attr(644, root, man) %{_mandir}/man8/mysqld.8*
%doc %attr(644, root, man) %{_mandir}/man1/mysqld_multi.1*
%doc %attr(644, root, man) %{_mandir}/man1/mysqld_safe.1*
......
......@@ -140,11 +140,19 @@ static signal_entry install_signal[]= {
{ SIGABRT, handle_core_signal },
{ SIGFPE, handle_core_signal },
{ SIGSEGV, handle_core_signal },
{ SIGBUS, handle_core_signal },
{ SIGXCPU, handle_core_signal },
{ SIGXFSZ, handle_core_signal },
{ SIGSYS, handle_core_signal },
{ SIGTRAP, handle_core_signal }
{ SIGBUS, handle_core_signal }
#ifdef SIGXCPU
, { SIGXCPU, handle_core_signal }
#endif
#ifdef SIGXCPU
, { SIGXFSZ, handle_core_signal }
#endif
#ifdef SIGXCPU
, { SIGSYS, handle_core_signal }
#endif
#ifdef SIGXCPU
, { SIGTRAP, handle_core_signal }
#endif
};
void
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment