File tree Expand file tree Collapse file tree 1 file changed +2
-4
lines changed Expand file tree Collapse file tree 1 file changed +2
-4
lines changed Original file line number Diff line number Diff line change @@ -105,18 +105,16 @@ _pysqlite_seterror(pysqlite_state *state, sqlite3 *db)
105
105
goto exit ;
106
106
}
107
107
108
- _Py_IDENTIFIER (sqlite_errorcode );
109
108
PyObject * code = PyLong_FromLong (errorcode );
110
109
if (code == NULL ) {
111
110
goto exit ;
112
111
}
113
- int rc = _PyObject_SetAttrId (exc , & PyId_sqlite_errorcode , code );
112
+ int rc = PyObject_SetAttrString (exc , "sqlite_errorcode" , code );
114
113
Py_DECREF (code );
115
114
if (rc < 0 ) {
116
115
goto exit ;
117
116
}
118
117
119
- _Py_IDENTIFIER (sqlite_errorname );
120
118
const char * error_name = pysqlite_error_name (errorcode );
121
119
PyObject * name ;
122
120
if (error_name ) {
@@ -128,7 +126,7 @@ _pysqlite_seterror(pysqlite_state *state, sqlite3 *db)
128
126
if (name == NULL ) {
129
127
goto exit ;
130
128
}
131
- rc = _PyObject_SetAttrId (exc , & PyId_sqlite_errorname , name );
129
+ rc = PyObject_SetAttrString (exc , "sqlite_errorname" , name );
132
130
Py_DECREF (name );
133
131
if (rc < 0 ) {
134
132
goto exit ;
You can’t perform that action at this time.
0 commit comments