Merge pull request #4946 from nulano/mingw64-tk

Fix crash in ImageTk.PhotoImage on mingw64
This commit is contained in:
Andrew Murray 2020-10-05 09:43:52 +11:00 committed by GitHub
commit e80f06147b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 3 deletions

View File

@ -2,7 +2,7 @@ import pytest
from PIL import Image
from .helper import assert_image_equal, hopper, is_mingw
from .helper import assert_image_equal, hopper
try:
import tkinter as tk
@ -52,7 +52,6 @@ def test_kw():
assert im is None
@pytest.mark.skipif(is_mingw(), reason="Segmentation fault")
def test_photoimage():
for mode in TK_MODES:
# test as image:

View File

@ -63,7 +63,7 @@ ImagingFind(const char* name)
Py_ssize_t id;
/* FIXME: use CObject instead? */
#if defined(_MSC_VER) && defined(_WIN64)
#if defined(_WIN64)
id = _atoi64(name);
#else
id = atol(name);