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
a3f4ec45
Commit
a3f4ec45
authored
Dec 07, 2005
by
unknown
Browse files
Options
Browse Files
Download
Plain Diff
Merge mysql.com:/home/jimw/my/mysql-5.0-15510
into mysql.com:/home/jimw/my/mysql-5.0-release
parents
83142adf
4ea36b7a
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
36 additions
and
1 deletion
+36
-1
sql-common/client.c
sql-common/client.c
+1
-1
tests/mysql_client_test.c
tests/mysql_client_test.c
+35
-0
No files found.
sql-common/client.c
View file @
a3f4ec45
...
...
@@ -715,6 +715,7 @@ void free_old_query(MYSQL *mysql)
init_alloc_root
(
&
mysql
->
field_alloc
,
8192
,
0
);
/* Assume rowlength < 8192 */
mysql
->
fields
=
0
;
mysql
->
field_count
=
0
;
/* For API */
mysql
->
warning_count
=
0
;
mysql
->
info
=
0
;
DBUG_VOID_RETURN
;
}
...
...
@@ -2484,7 +2485,6 @@ get_info:
DBUG_RETURN
(
1
);
mysql
->
status
=
MYSQL_STATUS_GET_RESULT
;
mysql
->
field_count
=
(
uint
)
field_count
;
mysql
->
warning_count
=
0
;
DBUG_PRINT
(
"exit"
,(
"ok"
));
DBUG_RETURN
(
0
);
}
...
...
tests/mysql_client_test.c
View file @
a3f4ec45
...
...
@@ -14590,6 +14590,40 @@ static void test_bug14845()
myquery
(
rc
);
}
/*
Bug #15510: mysql_warning_count returns 0 after mysql_stmt_fetch which
should warn
*/
static
void
test_bug15510
()
{
MYSQL_STMT
*
stmt
;
MYSQL_RES
*
res
;
int
rc
;
const
char
*
query
=
"select 1 from dual where 1/0"
;
myheader
(
"test_bug15510"
);
rc
=
mysql_query
(
mysql
,
"set @@sql_mode='ERROR_FOR_DIVISION_BY_ZERO'"
);
myquery
(
rc
);
stmt
=
mysql_stmt_init
(
mysql
);
rc
=
mysql_stmt_prepare
(
stmt
,
query
,
strlen
(
query
));
check_execute
(
stmt
,
rc
);
rc
=
mysql_stmt_execute
(
stmt
);
check_execute
(
stmt
,
rc
);
rc
=
mysql_stmt_fetch
(
stmt
);
DIE_UNLESS
(
mysql_warning_count
(
mysql
));
/* Cleanup */
mysql_stmt_close
(
stmt
);
rc
=
mysql_query
(
mysql
,
"set @@sql_mode=''"
);
myquery
(
rc
);
}
/*
Read and parse arguments and MySQL options from my.cnf
*/
...
...
@@ -14849,6 +14883,7 @@ static struct my_tests_st my_tests[]= {
{
"test_bug13488"
,
test_bug13488
},
{
"test_bug13524"
,
test_bug13524
},
{
"test_bug14845"
,
test_bug14845
},
{
"test_bug15510"
,
test_bug15510
},
{
0
,
0
}
};
...
...
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