File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed
Filter options
Expand file tree Collapse file tree 1 file changed +2
-2
lines changed
Original file line number Diff line number Diff line change @@ -293,7 +293,7 @@ static PyObject *Py_write_png(PyObject *self, PyObject *args, PyObject *kwds)
293
293
text[meta_pos].compression = PNG_TEXT_COMPRESSION_NONE;
294
294
#if PY3K
295
295
if (PyUnicode_Check (meta_key)) {
296
- PyObject *temp_key = PyUnicode_AsEncodedString (meta_key, " ASCII " , " strict" );
296
+ PyObject *temp_key = PyUnicode_AsEncodedString (meta_key, " latin_1 " , " strict" );
297
297
if (temp_key != NULL ) {
298
298
text[meta_pos].key = PyBytes_AsString (temp_key);
299
299
}
@@ -303,7 +303,7 @@ static PyObject *Py_write_png(PyObject *self, PyObject *args, PyObject *kwds)
303
303
text[meta_pos].key = NULL ; // Silently drops entry
304
304
}
305
305
if (PyUnicode_Check (meta_val)) {
306
- PyObject *temp_val = PyUnicode_AsEncodedString (meta_val, " ASCII " , " strict" );
306
+ PyObject *temp_val = PyUnicode_AsEncodedString (meta_val, " latin_1 " , " strict" );
307
307
if (temp_val != NULL ) {
308
308
text[meta_pos].text = PyBytes_AsString (temp_val);
309
309
}
You can’t perform that action at this time.
0 commit comments