Crash springboard when set repeating local notifications.

Originator:loiseau
Number:rdar://35810221 Date Originated:12/2/2017
Status:Closed Resolved:Duplicate of 35810633
Product:iOS Product Version:11.1.2
Classification:Bug Reproducible:Always
 
Area:
UserNotifications Framework

Summary:
It will crash springboard when you set up specified local notifications.

Steps to Reproduce:

Here is a reproducible app.
https://github.com/ktakayama/NotificationCrash
It is not reproduced by the simulator.
It seems to be reproduced only on actual device.

It is faster to have a look at the code
https://github.com/ktakayama/NotificationCrash/blob/master/NotificationCrash/ViewController.swift#L28-L34

Expected Results:
do not crash

Actual Results:
- black out your phone and restart springboard

Version/Build:
iOS 11.1.2, 11.1.1

Comments

Fix this on iOS11.2 🎉 https://support.apple.com/en-us/HT208332

The following code will be CPU usage to 100% and crash. It seems to be related to this problem.

let dateComponents = DateComponents(day: 1)

let trigger = UNCalendarNotificationTrigger(dateMatching: dateComponents, repeats: true)


Please note: Reports posted here will not necessarily be seen by Apple. All problems should be submitted at bugreport.apple.com before they are posted here. Please only post information for Radars that you have filed yourself, and please do not include Apple confidential information in your posts. Thank you!