Commit graph

153 commits

Author SHA1 Message Date
Nirbhay Choubey
39f71a296a Bug#11757855 - 49967: built-in libedit doesn't read
.editrc on linux.

MySQL client when build with libedit support ignores
.editrc at startup.

The reason for this regression was the incluison of a
safety check, issetugid(), which is not available on
some linux platforms.

Fixed by adding an equivalent check for platforms which
have get[e][u|g]id() set of functions.
2011-04-29 18:52:46 +05:30
Nirbhay Choubey
c08c4e1fd7 BUG#12329909 - BUILDING MYSQL WITH DEBUG SUPPORT
FAILS WITH LIBEDIT

Fixed by checking the return value of the write()
function calls and handling the open files and fd
appropriately.
2011-04-27 17:24:10 +05:30
Davi Arnaut
80246ac8b8 Bug#58057: 5.1 libmysql/libmysql.c unused variable/compile failure
Bug#57995: Compiler flag change build error on OSX 10.4: my_getncpus.c
Bug#57996: Compiler flag change build error on OSX 10.5 : bind.c
Bug#57994: Compiler flag change build error : my_redel.c
Bug#57993: Compiler flag change build error on FreeBsd 7.0 : regexec.c
Bug#57992: Compiler flag change build error on FreeBsd : mf_keycache.c
Bug#57997: Compiler flag change build error on OSX 10.6: debug_sync.cc

Fix assorted compiler generated warnings.
2010-11-10 19:14:47 -02:00
Davi Arnaut
560ee2158d Bug#45288: pb2 returns a lot of compilation warnings
Fix assorted warnings that are generated in optimized builds.
Most of it is silencing variables that are set but unused.

This patch also introduces the MY_ASSERT_UNREACHABLE macro
which helps the compiler to deduce that a certain piece of
code is unreachable.
2010-10-20 16:21:40 -02:00
Davi Arnaut
39e9bde2c0 Bug#45288: pb2 returns a lot of compilation warnings
Tag or remove unused arguments and variables.
2010-10-19 20:36:59 -02:00
Davi Arnaut
d6204ecac2 Bug#45288: pb2 returns a lot of compilation warnings on linux
Fix assorted compiler warnings on Mac OS X.
2010-10-19 11:49:31 -02:00
Davi Arnaut
93fb8bb235 Bug#53445: Build with -Wall and fix warnings that it generates
Apart strict-aliasing warnings, fix the remaining warnings
generated by GCC 4.4.4 -Wall and -Wextra flags.

One major source of warnings was the in-house function my_bcmp
which (unconventionally) took pointers to unsigned characters
as the byte sequences to be compared. Since my_bcmp and bcmp
are deprecated functions whose only difference with memcmp is
the return value, every use of the function is replaced with
memcmp as the special return value wasn't actually being used
by any caller.

There were also various other warnings, mostly due to type
mismatches, missing return values, missing prototypes, dead
code (unreachable) and ignored return values.
2010-07-02 15:30:47 -03:00
Staale Smedseng
5181551dee Bug #43414 Parenthesis (and other) warnings compiling
MySQL with gcc 4.3.2
      
This is the final patch in the context of this bug.
2010-02-22 14:23:47 +01:00
Staale Smedseng
8b9843408d Bug #43414 Parenthesis (and other) warnings compiling MySQL
with gcc 4.3.2

Cleaning up warnings not present in 5.0.
2009-09-23 15:21:29 +02:00
Jonathan Perkin
b74d8fa21e Merge from mysql-5.1.38-release 2009-09-03 01:48:06 +02:00
Staale Smedseng
f59ef9eafa Merge from 5.0 for 43414 2009-08-28 18:21:54 +02:00
Staale Smedseng
2217de2513 Bug #43414 Parenthesis (and other) warnings compiling MySQL
with gcc 4.3.2
      
This patch fixes a number of GCC warnings about variables used
before initialized. A new macro UNINIT_VAR() is introduced for
use in the variable declaration, and LINT_INIT() usage will be
gradually deprecated. (A workaround is used for g++, pending a
patch for a g++ bug.)
      
GCC warnings for unused results (attribute warn_unused_result)
for a number of system calls (present at least in later
Ubuntus, where the usual void cast trick doesn't work) are
also fixed.
2009-08-28 17:51:31 +02:00
Jonathan Perkin
17476e2797 Build fixes for Windows, AIX, HP/UX and Sun Studio11, from Timothy Smith. 2009-08-14 17:18:52 +02:00
Staale Smedseng
f46dba5a5f Bug #43397 mysql headers redefine pthread_mutex_init
unnecessarily
      
The problem is that libmysqlclient.so is built with THREAD
undefined, while a client compiling against the same header
files will see THREAD as defined and definitions in
my_pthread.h will be included, possibly resulting in undefined
symbols that cannot be resolved with libmysqlclient.so.
      
The suggested solution is to require that clients wanting to
link with libmysqlclient.so should be built with
MYSQL_CLIENT_NO_THREADS defined. This requires a documentation
change, and more details for this will be supplied if this
patch is approved.
      
The MYSQL_CLIENT_NO_THREADS define was renamed from
UNDEF_THREADS_HACK, to get a more suitable (less suspicious)
name for the define. (The UNDEF_THREADS_HACK is retained for
backwards compatibility, though.)
      
This patch is also in anticipation of WL#4958, which will
remove this problem altogether by dropping the building of
libmysqlclient.
2009-07-08 16:49:45 +02:00
Staale Smedseng
db1591a7a2 Merge from 5.0 2009-06-29 16:00:47 +02:00
Staale Smedseng
19dfaa5824 Merge from 5.0-bt 2009-06-29 15:17:01 +02:00
Tatiana A. Nurnberg
6723422415 Addendum to Bug #45286: backport macro name form other tree
use same (slightly unwieldy) name in all trees; fix before this version goes "public".
bless ctype to avoid upmerge conflict, le sigh.
2009-06-06 15:05:44 +02:00
Georgi Kodinov
845f968369 merged 5.0-bugteam -> 5.1-bugteam 2009-06-05 19:40:36 +03:00
Georgi Kodinov
c6fdeff0c7 Addendum to Bug #45286 : implement reviewer's remarks. 2009-06-05 19:23:44 +03:00
Georgi Kodinov
5db8276fe3 Bug #45286: compilation warnings on mysql-5.0-bugteam on MacOSX
Implemented a way to circumvent the always true comparison by
having nested macros (as suggested on review).
2009-06-05 18:14:56 +03:00
Georgi Kodinov
1a8eb91e06 automerge 2009-06-05 15:30:57 +03:00
Georgi Kodinov
5ec61b304c Bug #45286: compilation warnings on mysql-5.0-bugteam on MacOSX
Fixed the 5.0-bugteam MacOSX warnings.
2009-06-05 15:05:26 +03:00
Staale Smedseng
fc35ded3f4 Merge from 5.0-bugteam 2009-04-16 11:47:21 +02:00
Staale Smedseng
4387f01efd Bug#42430 Final commit to 5.0-bugteam 2009-04-16 11:40:51 +02:00
Timothy Smith
a43bab0a8b merge -5.0 into -5.1 (minor conflicts resolved) 2009-04-01 23:19:04 -06:00
kent.boortz@sun.com
677b00faf6 cmd-line-utils/libedit/readline/readline.h
- Header <sys/ttydefaults.h> missing or not usable on QNX and OpenServer 6

include/my_global.h
 - Moved down definition of function rint(), as for some platforms (in
   this case Netware) 'longlong' is not defined until later in
   "my_global.h"
2009-03-19 16:40:54 +01:00
kent.boortz@sun.com
e60cecab80 Back patched libedit portability changes from 5.1.32 2009-03-09 22:16:24 +01:00
kent.boortz@sun.com
a6c1702321 Disabled libedit use of '__weak_reference' on FreeBSD, doesn't compile 2009-02-14 01:43:21 +01:00
jperkin@sun.com
5caead0119 More portability fixes. 2009-02-12 16:01:38 +01:00
kent.boortz@sun.com
8daaad027f Exclude libedit inclusion of <sys/ttydefaults.h> on AIX as well 2009-02-12 03:31:31 +01:00
kent.boortz@sun.com
1d4e64ea07 Changed to use the correct "__sun" and "__hpux" predefined
preprocessor symbols in libedit
2009-02-11 21:33:46 +01:00
Georgi Kodinov
bf63b815fa merged 5.0-bugteam to 5.1-bugteam 2009-02-10 20:22:34 +02:00
Georgi Kodinov
1a7b0ec920 fixed a libedit compilation problem 2009-02-10 20:19:03 +02:00
Georgi Kodinov
6387fe92ea merged 5.0-bugteam -> 5.1-bugteam 2009-02-10 16:26:18 +02:00
Georgi Kodinov
773b18e69a From jperkin : Merge libedit 2.11 and related files,
based on NetBSD CVS as of 2009/02/06 20:09:00.
2009-02-10 14:39:14 +02:00
antony@pcg5ppc.xiphis.org
820068f1b7 Merge pcg5ppc.xiphis.org:/Network/Servers/anubis.xiphis.org/home/antony/work/mysql-5.1-engines
into  pcg5ppc.xiphis.org:/Network/Servers/anubis.xiphis.org/home/antony/work/merge.20080307/mysql-5.1
2008-03-07 13:46:29 -08:00
antony@pcg5ppc.xiphis.org
9c4e4640ad Merge pcg5ppc.xiphis.org:/Network/Servers/anubis.xiphis.org/home/antony/work/mysql-5.0-engines
into  pcg5ppc.xiphis.org:/Network/Servers/anubis.xiphis.org/home/antony/work/merge.20080307/mysql-5.0
2008-03-07 13:41:11 -08:00
bar@bar.myoffice.izhnet.ru
d079c2c49d Merge mysql.com:/home/bar/mysql-work/mysql-5.0-engines
into  mysql.com:/home/bar/mysql-work/mysql-5.1-engines
2008-03-07 14:58:12 +04:00
bar@mysql.com/bar.myoffice.izhnet.ru
640a4d59fd Bug#23097 mysql can't insert korean on mysql prompt.
Problem: libedit is a very pure-ASCII oriented library,
and it is not aware of extended (0x80..0xFF) or even multi-byte
characters. It considered such characters as non-printable
and didn't allow to input them.
Fix: make libedit think that all bytes >= 0x80 are printable.
2008-03-04 16:13:08 +04:00
df@pippilotta.erinye.com
84efc3cc67 Merge pippilotta.erinye.com:/shared/home/df/mysql/build/mysql-5.0-build
into  pippilotta.erinye.com:/shared/home/df/mysql/build/mysql-5.1-build
2008-01-23 17:43:46 +01:00
df@pippilotta.erinye.com
0ac55ddef2 use correct config_readline.h file 2008-01-03 14:26:41 +01:00
df@pippilotta.erinye.com
af3e8cb12d Merge pippilotta.erinye.com:/shared/home/df/mysql/build/mysql-5.0-build-work-18431
into  pippilotta.erinye.com:/shared/home/df/mysql/build/mysql-5.1-build-work-18431
2007-11-19 14:55:15 +01:00
df@pippilotta.erinye.com
44ab4b2e7d Update readline to version 5.2. This fixes bug#18431. 2007-11-19 14:38:08 +01:00
kent@kent-amd64.(none)
b5e97b4b04 Merge mysql.com:/home/kent/bk/bug24809/mysql-5.0-build
into  mysql.com:/home/kent/bk/bug24809/mysql-5.1-build
2007-10-31 10:52:18 +01:00
kent@mysql.com/kent-amd64.(none)
2f88dce6ff Makefile.am:
Ensure use of libedit "config.h" by adding "-I. -I$(srcdir)" to DEFS,
  work around for problem with automake 1.10 (bug#24809)
2007-10-30 20:54:31 +01:00
kent@mysql.com/kent-amd64.(none)
18acdc7581 make_binary_distribution.sh:
Use 'make install' to create the package
Makefile.am:
  Added 'pkgsuppdir' to control location separately
  Pass on mandir and infodir
  Don't install headers
2007-09-26 20:19:33 +02:00
kent@kent-amd64.(none)
fd3b865149 Merge mysql.com:/home/kent/bk/config_h/mysql-5.0-build
into  mysql.com:/home/kent/bk/config_h/mysql-5.1-build
2007-07-30 21:45:06 +02:00
kent@mysql.com/kent-amd64.(none)
a9d2569cba Generate "config.h" directly into the "include" directory, later copied
to "my_config.h". Not to pollute the top directory, and to get more control
over what is included. Made the include path for "libedit" pick up its own
"config.h" first.
2007-07-30 21:09:45 +02:00
msvensson@pilot.(none)
f8c036a052 Merge pilot.(none):/data/msvensson/mysql/mysql-5.0-maint
into  pilot.(none):/data/msvensson/mysql/mysql-5.1-new-maint
2007-06-07 09:22:26 +02:00
msvensson@pilot.(none)
7368985cfa Merge pilot.(none):/data/msvensson/mysql/mysql-4.1-maint
into  pilot.(none):/data/msvensson/mysql/mysql-5.0-maint
2007-06-07 09:21:33 +02:00