bootstrap-markdown icon indicating copy to clipboard operation
bootstrap-markdown copied to clipboard

Editor crashes browsers on iOS 8.3

Open Mia-X opened this issue 9 years ago • 3 comments

I have noticed that the editor crashes mobile browsers (Safari & Chrome) on iOS 8.3. The bug occurs when the user tries to add an url or image. The prompt box opens the first time, but not a second time. I was able to reproduce the bug on multiple iOS devices.

You can see the problem in this short video (in the end Chrome does not respond anymore): https://vid.me/cbIp

Device Log:

Process:             MobileSafari [1887]
Path:                /Applications/MobileSafari.app/MobileSafari
Identifier:          com.apple.mobilesafari
Version:             600.1.4 (8.0)
Code Type:           ARM (Native)
Parent Process:      launchd [1]

Date/Time:           2015-05-16 13:18:38.266 -0700
Launch Time:         2015-05-16 13:08:02.442 -0700
OS Version:          iOS 8.3 (12F70)
Report Version:      105

Exception Type:  EXC_BAD_ACCESS (SIGSEGV)
Exception Subtype: KERN_INVALID_ADDRESS at 0xd000000c
Triggered by Thread:  0

Thread 0 name:  Dispatch queue: com.apple.main-thread
Thread 0 Crashed:
0   libobjc.A.dylib                 0x389c5f46 0x389b3000 + 77638
1   CoreFoundation                  0x2a60ce48 0x2a600000 + 52808
2   WebKit                          0x2e6f4fd4 0x2e693000 + 401364
3   WebKit                          0x2e7ae630 0x2e693000 + 1160752
4   WebKit                          0x2e7bd8bc 0x2e693000 + 1222844
5   WebKit                          0x2e7bd866 0x2e693000 + 1222758
6   WebKit                          0x2e7bc44a 0x2e693000 + 1217610
7   WebKit                          0x2e7b9e3c 0x2e693000 + 1207868
8   WebKit                          0x2e6fc7a6 0x2e693000 + 432038
9   WebKit                          0x2e7d796c 0x2e693000 + 1329516
10  WebKit                          0x2e6a2bee 0x2e693000 + 64494
11  WebKit                          0x2e6a13b8 0x2e693000 + 58296
12  WebKit                          0x2e6a2c86 0x2e693000 + 64646
13  JavaScriptCore                  0x2bc24742 0x2b91c000 + 3180354
14  JavaScriptCore                  0x2bc24b96 0x2b91c000 + 3181462
15  CoreFoundation                  0x2a6cdfac 0x2a600000 + 843692
16  CoreFoundation                  0x2a6cd3ba 0x2a600000 + 840634
17  CoreFoundation                  0x2a6cba20 0x2a600000 + 834080
18  CoreFoundation                  0x2a6181fc 0x2a600000 + 98812
19  CoreFoundation                  0x2a61800e 0x2a600000 + 98318
20  GraphicsServices                0x31ef71fc 0x31eee000 + 37372
21  UIKit                           0x2ddbca54 0x2dd4d000 + 457300
22  MobileSafari                    0x000da1c0 0xd2000 + 33216
23  libdyld.dylib                   0x38f45aac 0x38f44000 + 6828

Mia-X avatar May 16 '15 20:05 Mia-X

I have a related issue, that the add url/image button uses the almost obselete "prompt" function which produces an ugly 1990's modal dialog on desktop to enter image URL .. Maybe that is what crashes Safari for you? I plan to get around my issue by using hiddenButtons[] to hide the image/url buttons and add custom buttons to additionalButtons:[] to use a more pleasing bootstrap interface to enter urls/images. The custom buttons will also allow me to add addl. code to upload an image to my server

chetan-prime avatar May 17 '15 21:05 chetan-prime

Yes, it seems like that the prompt() function is the reason this bug. But I'm not sure why it's causing the browsers to crash. I was not able to reproduce this error outside of this plugin.

My current solution for this problem is to overwrite the default callback function before initializing the editor.

Mia-X avatar May 17 '15 23:05 Mia-X

Thanks for reporting guys. I'll take a look this week.

toopay avatar May 18 '15 05:05 toopay