Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
mariadb
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
mariadb
Commits
8bffa163
Commit
8bffa163
authored
Jan 19, 2010
by
Vladislav Vaintroub
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix various compiler/OS compatibility errors
parent
6b596534
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
25 additions
and
6 deletions
+25
-6
client/mysqltest.cc
client/mysqltest.cc
+16
-1
config.h.cmake
config.h.cmake
+1
-1
configure.cmake
configure.cmake
+7
-3
mysys/typelib.c
mysys/typelib.c
+1
-1
No files found.
client/mysqltest.cc
View file @
8bffa163
...
@@ -73,7 +73,7 @@
...
@@ -73,7 +73,7 @@
#define QUERY_REAP_FLAG 2
#define QUERY_REAP_FLAG 2
#ifndef HAVE_SETENV
#ifndef HAVE_SETENV
#error implement our portable setenv replacement in mysys
static
int
setenv
(
const
char
*
name
,
const
char
*
value
,
int
overwrite
)
#endif
#endif
enum
{
enum
{
...
@@ -9672,3 +9672,18 @@ void dynstr_append_sorted(DYNAMIC_STRING* ds, DYNAMIC_STRING *ds_input)
...
@@ -9672,3 +9672,18 @@ void dynstr_append_sorted(DYNAMIC_STRING* ds, DYNAMIC_STRING *ds_input)
delete_dynamic
(
&
lines
);
delete_dynamic
(
&
lines
);
DBUG_VOID_RETURN
;
DBUG_VOID_RETURN
;
}
}
#ifndef HAVE_SETENV
static
int
setenv
(
const
char
*
name
,
const
char
*
value
,
int
overwrite
)
{
size_t
buflen
=
strlen
(
name
)
+
strlen
(
value
)
+
2
;
char
*
envvar
=
malloc
(
buflen
);
if
(
!
envvar
)
return
ENOMEM
;
strcpy
(
envvar
,
name
);
strcat
(
envvar
,
"="
);
strcat
(
envvar
,
value
);
putenv
(
envvar
);
return
0
;
}
#endif
config.h.cmake
View file @
8bffa163
...
@@ -534,7 +534,7 @@
...
@@ -534,7 +534,7 @@
#cmakedefine strtok_r @strtok_r@
#cmakedefine strtok_r @strtok_r@
#cmakedefine strtoll @strtoll@
#cmakedefine strtoll @strtoll@
#cmakedefine strtoull @strtoull@
#cmakedefine strtoull @strtoull@
#if
def _WIN32
#if
(_MSC_VER > 1310)
#define HAVE_SETENV
#define HAVE_SETENV
#define setenv(a,b,c) _putenv_s(a,b)
#define setenv(a,b,c) _putenv_s(a,b)
#endif
#endif
...
...
configure.cmake
View file @
8bffa163
...
@@ -284,9 +284,13 @@ IF(UNIX)
...
@@ -284,9 +284,13 @@ IF(UNIX)
IF
(
NOT LIBM
)
IF
(
NOT LIBM
)
MY_SEARCH_LIBS
(
__infinity m LIBM
)
MY_SEARCH_LIBS
(
__infinity m LIBM
)
ENDIF
()
ENDIF
()
IF
(
NOT LIBM
)
MY_SEARCH_LIBS
(
rint m LIBM
)
IF
(
CMAKE_SYSTEM_NAME MATCHES
"SunOS"
)
# On Solaris, use of intrinsics will screw the lib search logic
# Force using -lm, so rint etc are found.
SET
(
LIBM m
)
ENDIF
()
ENDIF
()
MY_SEARCH_LIBS
(
gethostbyname_r
"nsl_r;nsl"
LIBNSL
)
MY_SEARCH_LIBS
(
gethostbyname_r
"nsl_r;nsl"
LIBNSL
)
MY_SEARCH_LIBS
(
bind
"bind;socket"
LIBBIND
)
MY_SEARCH_LIBS
(
bind
"bind;socket"
LIBBIND
)
MY_SEARCH_LIBS
(
crypt crypt LIBCRYPT
)
MY_SEARCH_LIBS
(
crypt crypt LIBCRYPT
)
...
...
mysys/typelib.c
View file @
8bffa163
...
@@ -326,7 +326,7 @@ my_ulonglong find_set_from_flags(const TYPELIB *lib, uint default_name,
...
@@ -326,7 +326,7 @@ my_ulonglong find_set_from_flags(const TYPELIB *lib, uint default_name,
my_ulonglong
flags_to_set
=
0
,
flags_to_clear
=
0
,
res
;
my_ulonglong
flags_to_set
=
0
,
flags_to_clear
=
0
,
res
;
my_bool
set_defaults
=
0
;
my_bool
set_defaults
=
0
;
*
err_pos
=
0
;
/
/ No error yet
*
err_pos
=
0
;
/
* No error yet */
if
(
str
!=
end
)
if
(
str
!=
end
)
{
{
const
char
*
start
=
str
;
const
char
*
start
=
str
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment