Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 1a9874b

Browse filesBrowse files
authored
raise InterfaceError when mysql_errno() returns 0 (PyMySQL#203)
1 parent bab17ed commit 1a9874b
Copy full SHA for 1a9874b

File tree

Expand file treeCollapse file tree

1 file changed

+3
-0
lines changed
Filter options
Expand file treeCollapse file tree

1 file changed

+3
-0
lines changed

‎_mysql.c

Copy file name to clipboardExpand all lines: _mysql.c
+3Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -112,6 +112,9 @@ _mysql_Exception(_mysql_ConnectionObject *c)
112112
}
113113
merr = mysql_errno(&(c->connection));
114114
switch (merr) {
115+
case 0:
116+
e = _mysql_InterfaceError;
117+
break;
115118
case CR_COMMANDS_OUT_OF_SYNC:
116119
case ER_DB_CREATE_EXISTS:
117120
case ER_SYNTAX_ERROR:

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.