Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

FIX: fix C90 compilation error for Tcl / Tk stuff #2033

Merged
merged 1 commit into from Aug 6, 2016
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
6 changes: 4 additions & 2 deletions Tk/tkImaging.c
Expand Up @@ -371,7 +371,8 @@ int load_tkinter_funcs(void)
#if PY_VERSION_HEX >= 0x03000000
char *fname2char(PyObject *fname)
{
PyObject *bytes = PyUnicode_EncodeFSDefault(fname);
PyObject* bytes;
bytes = PyUnicode_EncodeFSDefault(fname);
if (bytes == NULL) {
return NULL;
}
Expand All @@ -391,9 +392,10 @@ void *_dfunc(void *lib_handle, const char *func_name)
* Returns function pointer or NULL if not present.
*/

void* func;
/* Reset errors. */
dlerror();
void *func = dlsym(lib_handle, func_name);
func = dlsym(lib_handle, func_name);
if (func == NULL) {
const char *error = dlerror();
PyErr_SetString(PyExc_RuntimeError, error);
Expand Down