# HG changeset patch # User bsmith@81767d24-ef19-dc11-ae90-00e081727c95 # Date 1616025697 0 # Node ID 2a7fed3d11f581be332d4e3af288f95b1ed90ac4 # Parent 8d6ab1f46a29855e03c42d6b1a84d534442f6313 Mac: Switch to performSelector: instead of calling implementation directly. The parameter was NULL on ARM (M1) MacOS for some reason. We call directly other places too, so might need to check more places but this fixes the crashes. diff -r 8d6ab1f46a29 -r 2a7fed3d11f5 mac/dw.m --- a/mac/dw.m Wed Mar 17 03:17:58 2021 +0000 +++ b/mac/dw.m Thu Mar 18 00:01:37 2021 +0000 @@ -1237,12 +1237,7 @@ DWTID curr = pthread_self(); if(DWThread == (DWTID)-1 || DWThread == curr) - { - DWIMP imp = (DWIMP)[self methodForSelector:sel]; - - if(imp) - imp(self, sel, param); - } + [self performSelector:sel withObject:param]; else [self performSelectorOnMainThread:sel withObject:param waitUntilDone:YES]; }