mozilla-mobile / focus-ios

⚠️ Firefox Focus (iOS) has moved to a new repository. It is now developed and maintained as part of: https://github.com/mozilla-mobile/firefox-ios
Mozilla Public License 2.0
1.26k stars 263 forks source link

Focus crashes when turning the `ETP` ON or OFF #3131

Closed abodea closed 2 years ago

abodea commented 2 years ago

Steps to reproduce

  1. Tap on the ETP shield button.
  2. Turn the ETP On or Off.

    Expected behavior

    The ETP is turned off or on.

    Actual behavior

    Focus crashes when turning the ETP ON or OFF

    Device & build information

    • Device: iPad mini 5 (14.7.1).
    • Build version: 9000 (11745).

      Notes

      Attachments:

{"app_cohort":"2|date=1647855000000&sf=143487&tid=be53758970f512d75b0691b7c09d793b7eb9efb76fa81e89d9f1df61b60bc56c&ttype=i","app_name":"Firefox Klar","app_version":"9000","timestamp":"2022-03-23 04:31:07.00 +0200","slice_uuid":"4bcea037-9f0b-30c0-a7d1-957ddf03a628","adam_id":1073435754,"build_version":"11745","platform":2,"bundleID":"org.mozilla.ios.Klar","share_with_app_devs":0,"is_first_party":0,"bug_type":"109","os_version":"iPhone OS 14.7.1 (18G82)","incident_id":"0DC4ACC3-A1D8-4B43-8ACD-56CA54C598F2","name":"Firefox Klar","is_beta":1}
Incident Identifier: 0DC4ACC3-A1D8-4B43-8ACD-56CA54C598F2
Beta Identifier:     D323DD02-5174-4857-A29F-7FA777E911F6
Hardware Model:      iPad11,1
Process:             Firefox Klar [469]
Path:                /private/var/containers/Bundle/Application/025E6AAA-2DE7-49AD-9CFD-025F5728AD7D/Firefox Klar.app/Firefox Klar
Identifier:          org.mozilla.ios.Klar
Version:             11745 (9000)
AppStoreTools:       13E112
AppVariant:          1:iPad11,1:14
Beta:                YES
Code Type:           ARM-64 (Native)
Role:                Foreground
Parent Process:      launchd [1]
Coalition:           org.mozilla.ios.Klar [401]

Date/Time:           2022-03-23 04:31:07.3788 +0200
Launch Time:         2022-03-23 04:30:57.6069 +0200
OS Version:          iPhone OS 14.7.1 (18G82)
Release Type:        User
Baseband Version:    n/a
Report Version:      104

Exception Type:  EXC_CRASH (SIGABRT)
Exception Codes: 0x0000000000000000, 0x0000000000000000
Exception Note:  EXC_CORPSE_NOTIFY
Triggered by Thread:  0

Application Specific Information:
abort() called

Last Exception Backtrace:
(0x1ac44f708 0x1c0f597a8 0x1ac3513b8 0x1ad7274c4 0x1af036694 0x1af04fd80 0x1af04ff70 0x1af0500b0 0x1af07c180 0x1ae50f898 0x1ae506308 0x1af374af8 0x1ae5061c4 0x1ae506598 0x1ac03c81c 0x1ac04b910 0x1ae505d8c 0x1c01c9730 0x100e0572c 0x100e3a36c 0x1c0505620 0x1c0505da4 0x1c05162c8 0x1c0517980 0x1c0561ca4 0x1c05158e0 0x100e0e384 0x1aee4763c 0x1ae7796ac 0x1ae7799fc 0x1ae7a8f44 0x1ae7a8608 0x1ae7a9a44 0x1af31de70 0x1aee5089c 0x1aee3f214 0x1aee730e8 0x1ac3c8588 0x1ac3c26ac 0x1ac3c2c58 0x1ac3c2308 0x1c3a45734 0x1aee4075c 0x1aee45fcc 0x100d9a844 0x1ac07ecf8)

Thread 0 name:  Dispatch queue: com.apple.uikit.datasource.diffing
Thread 0 Crashed:
0   libsystem_kernel.dylib          0x00000001d9f9f334 0x1d9f76000 + 168756
1   libsystem_pthread.dylib         0x00000001f74a1a9c 0x1f749f000 + 10908
2   libsystem_c.dylib               0x00000001b5816b84 0x1b579f000 + 490372
3   libc++abi.dylib                 0x00000001c103abb8 0x1c1027000 + 80824
4   libc++abi.dylib                 0x00000001c102bec8 0x1c1027000 + 20168
5   libobjc.A.dylib                 0x00000001c0f3805c 0x1c0f31000 + 28764
6   libc++abi.dylib                 0x00000001c1039fa0 0x1c1027000 + 77728
7   libc++abi.dylib                 0x00000001c1039f2c 0x1c1027000 + 77612
8   libdispatch.dylib               0x00000001ac03c830 0x1ac038000 + 18480
9   libdispatch.dylib               0x00000001ac04b910 0x1ac038000 + 80144
10  UIKitCore                       0x00000001ae505d8c 0x1ae276000 + 2686348
11  libswiftUIKit.dylib             0x00000001c01c9730 0x1c01b0000 + 104240
12  Firefox Klar                    0x0000000100e0572c 0x100d94000 + 464684
13  Firefox Klar                    0x0000000100e3a36c 0x100d94000 + 680812
14  Combine                         0x00000001c0505620 0x1c04e8000 + 120352
15  Combine                         0x00000001c0505da4 0x1c04e8000 + 122276
16  Combine                         0x00000001c05162c8 0x1c04e8000 + 189128
17  Combine                         0x00000001c0517980 0x1c04e8000 + 194944
18  Combine                         0x00000001c0561ca4 0x1c04e8000 + 498852
19  Combine                         0x00000001c05158e0 0x1c04e8000 + 186592
20  Firefox Klar                    0x0000000100e0e384 0x100d94000 + 500612
21  UIKitCore                       0x00000001aee4763c 0x1ae276000 + 12391996
22  UIKitCore                       0x00000001ae7796ac 0x1ae276000 + 5256876
23  UIKitCore                       0x00000001ae7799fc 0x1ae276000 + 5257724
24  UIKitCore                       0x00000001ae7a8f44 0x1ae276000 + 5451588
25  UIKitCore                       0x00000001ae7a8608 0x1ae276000 + 5449224
26  UIKitCore                       0x00000001ae7a9a44 0x1ae276000 + 5454404
27  UIKitCore                       0x00000001af31de70 0x1ae276000 + 17464944
28  UIKitCore                       0x00000001aee5089c 0x1ae276000 + 12429468
29  UIKitCore                       0x00000001aee3f214 0x1ae276000 + 12358164
30  UIKitCore                       0x00000001aee730e8 0x1ae276000 + 12570856
31  CoreFoundation                  0x00000001ac3c8588 0x1ac326000 + 664968
32  CoreFoundation                  0x00000001ac3c26ac 0x1ac326000 + 640684
33  CoreFoundation                  0x00000001ac3c2c58 0x1ac326000 + 642136
34  CoreFoundation                  0x00000001ac3c2308 0x1ac326000 + 639752
35  GraphicsServices                0x00000001c3a45734 0x1c3a42000 + 14132
36  UIKitCore                       0x00000001aee4075c 0x1ae276000 + 12363612
37  UIKitCore                       0x00000001aee45fcc 0x1ae276000 + 12386252
38  Firefox Klar                    0x0000000100d9a844 0x100d94000 + 26692
39  libdyld.dylib                   0x00000001ac07ecf8 0x1ac07d000 + 7416

Thread 1:
0   libsystem_pthread.dylib         0x00000001f74a9744 0x1f749f000 + 42820

Thread 2:
0   libsystem_pthread.dylib         0x00000001f74a9744 0x1f749f000 + 42820

Thread 3:
0   libsystem_pthread.dylib         0x00000001f74a9744 0x1f749f000 + 42820

Thread 4:
0   libsystem_pthread.dylib         0x00000001f74a9744 0x1f749f000 + 42820

Thread 5 name:  com.apple.uikit.eventfetch-thread
Thread 5:
0   libsystem_kernel.dylib          0x00000001d9f7a4fc 0x1d9f76000 + 17660
1   libsystem_kernel.dylib          0x00000001d9f79884 0x1d9f76000 + 14468
2   CoreFoundation                  0x00000001ac3c8e58 0x1ac326000 + 667224
3   CoreFoundation                  0x00000001ac3c2cf8 0x1ac326000 + 642296
4   CoreFoundation                  0x00000001ac3c2308 0x1ac326000 + 639752
5   Foundation                      0x00000001ad6b1d8c 0x1ad6a9000 + 36236
6   Foundation                      0x00000001ad6b1c58 0x1ad6a9000 + 35928
7   UIKitCore                       0x00000001aeef5304 0x1ae276000 + 13103876
8   Foundation                      0x00000001ad82330c 0x1ad6a9000 + 1549068
9   libsystem_pthread.dylib         0x00000001f74a0bfc 0x1f749f000 + 7164
10  libsystem_pthread.dylib         0x00000001f74a9758 0x1f749f000 + 42840

Thread 6:
0   libsystem_pthread.dylib         0x00000001f74a9744 0x1f749f000 + 42820

https://user-images.githubusercontent.com/42831109/159241436-0c7243ce-9779-445e-ab38-de880eb7240d.mov

abodea commented 2 years ago

@razvanlitianu note that I tested this on iOS 13 and there is a start-up crash. Note that I've tested on a build before the 11684 when the start-up crash was introduced and Focus is not crashing when turning On the ETP.

Also, note that the ETP crash was not reproducible on the 11545 build, and it was introduced in the 11584 build.

abodea commented 2 years ago

Verified as fixed on v99 (11983) whit iPad mini 5 (14.1.7)